game engine: Use flags instead of hardcoded numbers for rna properties
authorSergej Reich <sergej.reich@googlemail.com>
Wed, 1 Aug 2012 17:19:32 +0000 (17:19 +0000)
committerSergej Reich <sergej.reich@googlemail.com>
Wed, 1 Aug 2012 17:19:32 +0000 (17:19 +0000)
source/blender/makesrna/intern/rna_scene.c

index 442f474eb2be7c735868e1b94a00226019650241..7148958943b6b7d344f67a2f01eff254244690bf 100644 (file)
@@ -37,6 +37,7 @@
 #include "DNA_particle_types.h"
 #include "DNA_scene_types.h"
 #include "DNA_userdef_types.h"
+#include "DNA_world_types.h"
 
 #include "BLI_math.h"
 
@@ -2635,13 +2636,13 @@ static void rna_def_scene_game_data(BlenderRNA *brna)
 
        /* mode */
        prop = RNA_def_property(srna, "use_occlusion_culling", PROP_BOOLEAN, PROP_NONE);
-       RNA_def_property_boolean_sdna(prop, NULL, "mode", (1 << 5)); /*XXX mode hardcoded  *//* WO_DBVT_CULLING */
+       RNA_def_property_boolean_sdna(prop, NULL, "mode", WO_DBVT_CULLING);
        RNA_def_property_ui_text(prop, "DBVT culling",
                                 "Use optimized Bullet DBVT tree for view frustum and occlusion culling");
        
        /* not used  *//* deprecated !!!!!!!!!!!!! */
        prop = RNA_def_property(srna, "use_activity_culling", PROP_BOOLEAN, PROP_NONE);
-       RNA_def_property_boolean_sdna(prop, NULL, "mode", (1 << 3)); /*XXX mode hardcoded */
+       RNA_def_property_boolean_sdna(prop, NULL, "mode", WO_ACTIVITY_CULLING);
        RNA_def_property_ui_text(prop, "Activity Culling", "Activity culling is enabled");
 
        /* not used  *//* deprecated !!!!!!!!!!!!! */