Adapt to previous noise normalization fix

This commit is contained in:
Michaël Lemaire 2013-06-09 15:11:03 +02:00
parent 701faf6ece
commit 06764427a6
4 changed files with 5 additions and 5 deletions

View file

@ -20,7 +20,7 @@ MainTerrainForm::MainTerrainForm(QWidget *parent) :
_form_helper->addPreview(ui->preview_shape, _renderer_shape);
_form_helper->addDoubleInputSlider(ui->input_scaling, &_terrain->scaling, 0.1, 3.0, 0.03, 0.3);
_form_helper->addDoubleInputSlider(ui->input_height, &_terrain->height, 1.0, 45.0, 0.3, 3.0);
_form_helper->addDoubleInputSlider(ui->input_height, &_terrain->height, 1.0, 90.0, 0.5, 5.0);
_form_helper->addDoubleInputSlider(ui->input_shadow_smoothing, &_terrain->shadow_smoothing, 0.0, 0.3, 0.003, 0.03);
_form_helper->addDoubleInputSlider(ui->input_water_height, &_terrain->water_height, -2.0, 2.0, 0.01, 0.1);

View file

@ -112,7 +112,7 @@ void cloudsLayerValidateDefinition(CloudsLayerDefinition* definition)
break;
}
noiseNormalizeAmplitude(definition->_coverage_noise, 0.0, 1.0, 0);
noiseNormalizeAmplitude(definition->_coverage_noise, -1.0, 3.0, 0);
noiseNormalizeAmplitude(definition->_shape_noise, -0.5, 0.5, 0);
}

View file

@ -27,13 +27,13 @@ static TerrainDefinition* _createDefinition()
{
TerrainDefinition* definition = malloc(sizeof(TerrainDefinition));
definition->height = 0.0;
definition->height = 1.0;
definition->scaling = 1.0;
definition->shadow_smoothing = 0.0;
definition->height_map = terrainHeightMapCreate(definition);
definition->water_height = -0.8;
definition->water_height = -0.3;
definition->_height_noise = noiseCreateGenerator();

View file

@ -19,7 +19,7 @@ void terrainAutoPreset(TerrainDefinition* definition, TerrainPreset preset)
noiseNormalizeAmplitude(definition->_height_noise, -1.0, 1.0, 0);
noiseSetFunctionParams(definition->_height_noise, NOISE_FUNCTION_SIMPLEX, 0.0, 0.0);
definition->scaling = 1.0;
definition->height = 15.0;
definition->height = 30.0;
definition->shadow_smoothing = 0.03;
break;
default: