diff --git a/TODO b/TODO index a7fe1b8..e554acb 100644 --- a/TODO +++ b/TODO @@ -11,7 +11,8 @@ Technology Preview 2 : => Find a proper model for night sky (maybe Shirley) - InputInt doesn't honor small_step. - Keep skydome lights in cache for a render. -- Add buttons to restore "auto" default values in tabs and dialogs. +- Add buttons to restore "auto" default values in tabs and dialogs (with several auto presets). +- Clouds should keep distance to ground. - Add "hardness to light" and shadow control ("minimum lighting") to material. Technlogy Preview 3 : diff --git a/lib_paysages/auto.c b/lib_paysages/auto.c index e2d4a99..d0dd8fc 100644 --- a/lib_paysages/auto.c +++ b/lib_paysages/auto.c @@ -80,7 +80,7 @@ void autoGenRealisticLandscape(int seed) /* Water */ water = waterCreateDefinition(); - water.height = -5.0; + water.height = -4.0; water.transparency = 0.5; water.reflection = 0.4; water.transparency_depth = 6.0; diff --git a/lib_paysages/clouds.c b/lib_paysages/clouds.c index e495523..cf4bc45 100644 --- a/lib_paysages/clouds.c +++ b/lib_paysages/clouds.c @@ -89,11 +89,11 @@ CloudsLayerDefinition* cloudsLayerCreateDefinition() result->lighttraversal = 7.0; result->minimumlight = 0.4; result->shape_scaling = 10.0; - result->edge_scaling = 0.3; - result->edge_length = 0.4; - result->base_coverage = 0.35; + result->edge_scaling = 0.8; + result->edge_length = 0.3; + result->base_coverage = 0.4; result->shape_noise = noiseCreateGenerator(); - noiseAddLevelsSimple(result->shape_noise, 6, 1.0, 1.0); + noiseAddLevelsSimple(result->shape_noise, 2, 1.0, 1.0); noiseSetFunctionParams(result->shape_noise, NOISE_FUNCTION_SIMPLEX, 0.3); result->edge_noise = noiseCreateGenerator(); noiseAddLevelsSimple(result->edge_noise, 8, 1.0, 1.0); @@ -278,7 +278,7 @@ static inline Vector3 _getNormal(CloudsLayerDefinition* layer, Vector3 position, static int _optimizeSearchLimits(CloudsLayerDefinition* layer, Vector3* start, Vector3* end) { Vector3 diff; - + if (start->y > layer->lower_altitude + layer->thickness) { if (end->y >= layer->lower_altitude + layer->thickness) @@ -314,7 +314,7 @@ static int _optimizeSearchLimits(CloudsLayerDefinition* layer, Vector3* start, V else /* start is inside layer */ { diff = v3Sub(*end, *start); - if (end->y > layer->thickness) + if (end->y > layer->lower_altitude + layer->thickness) { *end = v3Add(*start, v3Scale(diff, (layer->lower_altitude + layer->thickness - start->y) / diff.y)); }