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:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-09-08 13:46:31 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-09-08 13:46:31 +0400
commit279d64def710f90579c096ae43699daf742c73a5 (patch)
tree26e72be3bb149c2647304d3d4f4f559daee11a44 /source/blender
parent1f0bb0e0353687c17738608d884077dc6779638d (diff)
Fix #28545: User Preferences - System Tab - Reset All To Default Values on OpenGL Lights
Added default direction to light.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/makesrna/intern/rna_userdef.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_userdef.c b/source/blender/makesrna/intern/rna_userdef.c
index 66c4e7245c4..4bc828cdc4f 100644
--- a/source/blender/makesrna/intern/rna_userdef.c
+++ b/source/blender/makesrna/intern/rna_userdef.c
@@ -1959,6 +1959,7 @@ static void rna_def_userdef_solidlight(BlenderRNA *brna)
{
StructRNA *srna;
PropertyRNA *prop;
+ static float default_dir[3] = {0.f, 1.f, 0.f};
srna= RNA_def_struct(brna, "UserSolidLight", NULL);
RNA_def_struct_sdna(srna, "SolidLight");
@@ -1972,6 +1973,7 @@ static void rna_def_userdef_solidlight(BlenderRNA *brna)
prop= RNA_def_property(srna, "direction", PROP_FLOAT, PROP_DIRECTION);
RNA_def_property_float_sdna(prop, NULL, "vec");
RNA_def_property_array(prop, 3);
+ RNA_def_property_float_array_default(prop, default_dir);
RNA_def_property_ui_text(prop, "Direction", "The direction that the OpenGL light is shining");
RNA_def_property_update(prop, 0, "rna_UserDef_viewport_lights_update");