Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2022-07-19 17:35:53 +0300
committerClément Foucault <foucault.clem@gmail.com>2022-07-19 17:36:57 +0300
commitad5e3d30a2d2d21771140c9d877e1d7dedd560f6 (patch)
treeda61870eb352ddf3a93ece22a90bb6ee2990e545 /source/blender/makesrna/intern/rna_nodetree.c
parent2e3fb581280d637d92eb639b90e82f71e7f37ca3 (diff)
Nishita sky: Increase elevation range
The Nishita sky texture currently only allows moving the sun to the zenith. The problem is if you want to animate the passing of a full night-day-night cycle. Currently it's not easy to do due to this limitation. The patch makes it so users can easily animate the sun moving from sunrise to sunset by expanding the max sun elevation to go 360° instead of 90°. Reviewed By: fclem Differential Revision: https://developer.blender.org/D13724
Diffstat (limited to 'source/blender/makesrna/intern/rna_nodetree.c')
-rw-r--r--source/blender/makesrna/intern/rna_nodetree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_nodetree.c b/source/blender/makesrna/intern/rna_nodetree.c
index 386ef3f74a3..80217decb13 100644
--- a/source/blender/makesrna/intern/rna_nodetree.c
+++ b/source/blender/makesrna/intern/rna_nodetree.c
@@ -5282,7 +5282,7 @@ static void def_sh_tex_sky(StructRNA *srna)
prop = RNA_def_property(srna, "sun_elevation", PROP_FLOAT, PROP_ANGLE);
RNA_def_property_ui_text(prop, "Sun Elevation", "Sun angle from horizon");
- RNA_def_property_range(prop, -M_PI_2, M_PI_2);
+ RNA_def_property_ui_range(prop, -M_PI, M_PI, 1, 2);
RNA_def_property_float_default(prop, M_PI_2);
RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update");