Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_scene.c
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
| Show First 20 Lines • Show All 2,304 Lines • ▼ Show 20 Lines | static void rna_def_gpencil_brushes(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| RNA_def_property_srna(cprop, "GreasePencilBrushes"); | RNA_def_property_srna(cprop, "GreasePencilBrushes"); | ||||
| srna = RNA_def_struct(brna, "GreasePencilBrushes", NULL); | srna = RNA_def_struct(brna, "GreasePencilBrushes", NULL); | ||||
| RNA_def_struct_sdna(srna, "ToolSettings"); | RNA_def_struct_sdna(srna, "ToolSettings"); | ||||
| RNA_def_struct_ui_text(srna, "Grease Pencil Brushes", "Collection of grease pencil brushes"); | RNA_def_struct_ui_text(srna, "Grease Pencil Brushes", "Collection of grease pencil brushes"); | ||||
| func = RNA_def_function(srna, "new", "rna_GPencil_brush_new"); | func = RNA_def_function(srna, "new", "rna_GPencil_brush_new"); | ||||
| RNA_def_function_ui_description(func, "Add a new grease pencil brush"); | RNA_def_function_ui_description(func, "Add a new grease pencil brush"); | ||||
| parm = RNA_def_string(func, "name", "GPencilBrush", MAX_NAME, "Name", "Name of the brush"); | parm = RNA_def_string(func, "name", "GPencilBrush", MAX_NAME, "Name", "Name of the brush"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED); | RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); | ||||
| RNA_def_boolean(func, "set_active", 0, "Set Active", "Set the newly created brush to the active brush"); | RNA_def_boolean(func, "set_active", 0, "Set Active", "Set the newly created brush to the active brush"); | ||||
| parm = RNA_def_pointer(func, "palette", "GPencilBrush", "", "The newly created brush"); | parm = RNA_def_pointer(func, "palette", "GPencilBrush", "", "The newly created brush"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_GPencil_brush_remove"); | func = RNA_def_function(srna, "remove", "rna_GPencil_brush_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a grease pencil brush"); | RNA_def_function_ui_description(func, "Remove a grease pencil brush"); | ||||
| RNA_def_function_flag(func, FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "brush", "GPencilBrush", "", "The brush to remove"); | parm = RNA_def_pointer(func, "brush", "GPencilBrush", "", "The brush to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | ||||
| RNA_def_property_struct_type(prop, "GPencilBrush"); | RNA_def_property_struct_type(prop, "GPencilBrush"); | ||||
| RNA_def_property_pointer_funcs(prop, "rna_GPencilBrushes_active_get", "rna_GPencilBrushes_active_set", NULL, NULL); | RNA_def_property_pointer_funcs(prop, "rna_GPencilBrushes_active_get", "rna_GPencilBrushes_active_set", NULL, NULL); | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE); | RNA_def_property_flag(prop, PROP_EDITABLE); | ||||
| RNA_def_property_ui_text(prop, "Active Brush", "Current active brush"); | RNA_def_property_ui_text(prop, "Active Brush", "Current active brush"); | ||||
| prop = RNA_def_property(srna, "active_index", PROP_INT, PROP_UNSIGNED); | prop = RNA_def_property(srna, "active_index", PROP_INT, PROP_UNSIGNED); | ||||
| ▲ Show 20 Lines • Show All 1,272 Lines • ▼ Show 20 Lines | static void rna_def_freestyle_modules(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| RNA_def_function_flag(func, FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_pointer(func, "module", "FreestyleModuleSettings", "", "Newly created style module"); | parm = RNA_def_pointer(func, "module", "FreestyleModuleSettings", "", "Newly created style module"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_FreestyleSettings_module_remove"); | func = RNA_def_function(srna, "remove", "rna_FreestyleSettings_module_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a style module from scene render layer Freestyle settings"); | RNA_def_function_ui_description(func, "Remove a style module from scene render layer Freestyle settings"); | ||||
| RNA_def_function_flag(func, FUNC_USE_SELF_ID | FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_SELF_ID | FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "module", "FreestyleModuleSettings", "", "Style module to remove"); | parm = RNA_def_pointer(func, "module", "FreestyleModuleSettings", "", "Style module to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| } | } | ||||
| static void rna_def_freestyle_linesets(BlenderRNA *brna, PropertyRNA *cprop) | static void rna_def_freestyle_linesets(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| FunctionRNA *func; | FunctionRNA *func; | ||||
| PropertyRNA *parm; | PropertyRNA *parm; | ||||
| Show All 15 Lines | RNA_def_property_int_funcs(prop, "rna_FreestyleSettings_active_lineset_index_get", | ||||
| "rna_FreestyleSettings_active_lineset_index_range"); | "rna_FreestyleSettings_active_lineset_index_range"); | ||||
| RNA_def_property_ui_text(prop, "Active Line Set Index", "Index of active line set slot"); | RNA_def_property_ui_text(prop, "Active Line Set Index", "Index of active line set slot"); | ||||
| RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL); | RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL); | ||||
| func = RNA_def_function(srna, "new", "rna_FreestyleSettings_lineset_add"); | func = RNA_def_function(srna, "new", "rna_FreestyleSettings_lineset_add"); | ||||
| RNA_def_function_ui_description(func, "Add a line set to scene render layer Freestyle settings"); | RNA_def_function_ui_description(func, "Add a line set to scene render layer Freestyle settings"); | ||||
| RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_string(func, "name", "LineSet", 0, "", "New name for the line set (not unique)"); | parm = RNA_def_string(func, "name", "LineSet", 0, "", "New name for the line set (not unique)"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED); | RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); | ||||
| parm = RNA_def_pointer(func, "lineset", "FreestyleLineSet", "", "Newly created line set"); | parm = RNA_def_pointer(func, "lineset", "FreestyleLineSet", "", "Newly created line set"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_FreestyleSettings_lineset_remove"); | func = RNA_def_function(srna, "remove", "rna_FreestyleSettings_lineset_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a line set from scene render layer Freestyle settings"); | RNA_def_function_ui_description(func, "Remove a line set from scene render layer Freestyle settings"); | ||||
| RNA_def_function_flag(func, FUNC_USE_SELF_ID | FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_SELF_ID | FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "lineset", "FreestyleLineSet", "", "Line set to remove"); | parm = RNA_def_pointer(func, "lineset", "FreestyleLineSet", "", "Line set to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| } | } | ||||
| static void rna_def_freestyle_settings(BlenderRNA *brna) | static void rna_def_freestyle_settings(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| static EnumPropertyItem edge_type_negation_items[] = { | static EnumPropertyItem edge_type_negation_items[] = { | ||||
| ▲ Show 20 Lines • Show All 1,311 Lines • ▼ Show 20 Lines | static void rna_def_render_layers(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_NULL); | RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_NULL); | ||||
| RNA_def_property_ui_text(prop, "Active Render Layer", "Active Render Layer"); | RNA_def_property_ui_text(prop, "Active Render Layer", "Active Render Layer"); | ||||
| RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, "rna_Scene_glsl_update"); | RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, "rna_Scene_glsl_update"); | ||||
| func = RNA_def_function(srna, "new", "rna_RenderLayer_new"); | func = RNA_def_function(srna, "new", "rna_RenderLayer_new"); | ||||
| RNA_def_function_ui_description(func, "Add a render layer to scene"); | RNA_def_function_ui_description(func, "Add a render layer to scene"); | ||||
| RNA_def_function_flag(func, FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_string(func, "name", "RenderLayer", 0, "", "New name for the render layer (not unique)"); | parm = RNA_def_string(func, "name", "RenderLayer", 0, "", "New name for the render layer (not unique)"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED); | RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); | ||||
| parm = RNA_def_pointer(func, "result", "SceneRenderLayer", "", "Newly created render layer"); | parm = RNA_def_pointer(func, "result", "SceneRenderLayer", "", "Newly created render layer"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_RenderLayer_remove"); | func = RNA_def_function(srna, "remove", "rna_RenderLayer_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a render layer"); | RNA_def_function_ui_description(func, "Remove a render layer"); | ||||
| RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_REPORTS | FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_REPORTS | FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_pointer(func, "layer", "SceneRenderLayer", "", "Render layer to remove"); | parm = RNA_def_pointer(func, "layer", "SceneRenderLayer", "", "Render layer to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| } | } | ||||
| /* Render Views - MultiView */ | /* Render Views - MultiView */ | ||||
| static void rna_def_scene_render_view(BlenderRNA *brna) | static void rna_def_scene_render_view(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| ▲ Show 20 Lines • Show All 53 Lines • ▼ Show 20 Lines | static void rna_def_render_views(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_NULL); | RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_NULL); | ||||
| RNA_def_property_ui_text(prop, "Active Render View", "Active Render View"); | RNA_def_property_ui_text(prop, "Active Render View", "Active Render View"); | ||||
| RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL); | RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL); | ||||
| func = RNA_def_function(srna, "new", "rna_RenderView_new"); | func = RNA_def_function(srna, "new", "rna_RenderView_new"); | ||||
| RNA_def_function_ui_description(func, "Add a render view to scene"); | RNA_def_function_ui_description(func, "Add a render view to scene"); | ||||
| RNA_def_function_flag(func, FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_string(func, "name", "RenderView", 0, "", "New name for the marker (not unique)"); | parm = RNA_def_string(func, "name", "RenderView", 0, "", "New name for the marker (not unique)"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED); | RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); | ||||
| parm = RNA_def_pointer(func, "result", "SceneRenderView", "", "Newly created render view"); | parm = RNA_def_pointer(func, "result", "SceneRenderView", "", "Newly created render view"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_RenderView_remove"); | func = RNA_def_function(srna, "remove", "rna_RenderView_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a render view"); | RNA_def_function_ui_description(func, "Remove a render view"); | ||||
| RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_REPORTS | FUNC_USE_SELF_ID); | RNA_def_function_flag(func, FUNC_USE_MAIN | FUNC_USE_REPORTS | FUNC_USE_SELF_ID); | ||||
| parm = RNA_def_pointer(func, "view", "SceneRenderView", "", "Render view to remove"); | parm = RNA_def_pointer(func, "view", "SceneRenderView", "", "Render view to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| } | } | ||||
| static void rna_def_image_format_stereo3d_format(BlenderRNA *brna) | static void rna_def_image_format_stereo3d_format(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| /* rna_enum_stereo3d_display_items, without (S3D_DISPLAY_PAGEFLIP) */ | /* rna_enum_stereo3d_display_items, without (S3D_DISPLAY_PAGEFLIP) */ | ||||
| ▲ Show 20 Lines • Show All 1,551 Lines • ▼ Show 20 Lines | static void rna_def_scene_objects(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| srna = RNA_def_struct(brna, "SceneObjects", NULL); | srna = RNA_def_struct(brna, "SceneObjects", NULL); | ||||
| RNA_def_struct_sdna(srna, "Scene"); | RNA_def_struct_sdna(srna, "Scene"); | ||||
| RNA_def_struct_ui_text(srna, "Scene Objects", "Collection of scene objects"); | RNA_def_struct_ui_text(srna, "Scene Objects", "Collection of scene objects"); | ||||
| func = RNA_def_function(srna, "link", "rna_Scene_object_link"); | func = RNA_def_function(srna, "link", "rna_Scene_object_link"); | ||||
| RNA_def_function_ui_description(func, "Link object to scene, run scene.update() after"); | RNA_def_function_ui_description(func, "Link object to scene, run scene.update() after"); | ||||
| RNA_def_function_flag(func, FUNC_USE_CONTEXT | FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_CONTEXT | FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "object", "Object", "", "Object to add to scene"); | parm = RNA_def_pointer(func, "object", "Object", "", "Object to add to scene"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED); | ||||
| parm = RNA_def_pointer(func, "base", "ObjectBase", "", "The newly created base"); | parm = RNA_def_pointer(func, "base", "ObjectBase", "", "The newly created base"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "unlink", "rna_Scene_object_unlink"); | func = RNA_def_function(srna, "unlink", "rna_Scene_object_unlink"); | ||||
| RNA_def_function_ui_description(func, "Unlink object from scene"); | RNA_def_function_ui_description(func, "Unlink object from scene"); | ||||
| RNA_def_function_flag(func, FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "object", "Object", "", "Object to remove from scene"); | parm = RNA_def_pointer(func, "object", "Object", "", "Object to remove from scene"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED); | ||||
| prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | ||||
| RNA_def_property_struct_type(prop, "Object"); | RNA_def_property_struct_type(prop, "Object"); | ||||
| RNA_def_property_pointer_funcs(prop, "rna_Scene_active_object_get", "rna_Scene_active_object_set", NULL, NULL); | RNA_def_property_pointer_funcs(prop, "rna_Scene_active_object_get", "rna_Scene_active_object_set", NULL, NULL); | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_UNLINK); | RNA_def_property_flag(prop, PROP_EDITABLE | PROP_NEVER_UNLINK); | ||||
| RNA_def_property_ui_text(prop, "Active Object", "Active object for this scene"); | RNA_def_property_ui_text(prop, "Active Object", "Active object for this scene"); | ||||
| /* Could call: ED_base_object_activate(C, scene->basact); | /* Could call: ED_base_object_activate(C, scene->basact); | ||||
| * but would be a bad level call and it seems the notifier is enough */ | * but would be a bad level call and it seems the notifier is enough */ | ||||
| Show All 34 Lines | static void rna_def_timeline_markers(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| RNA_def_property_srna(cprop, "TimelineMarkers"); | RNA_def_property_srna(cprop, "TimelineMarkers"); | ||||
| srna = RNA_def_struct(brna, "TimelineMarkers", NULL); | srna = RNA_def_struct(brna, "TimelineMarkers", NULL); | ||||
| RNA_def_struct_sdna(srna, "Scene"); | RNA_def_struct_sdna(srna, "Scene"); | ||||
| RNA_def_struct_ui_text(srna, "Timeline Markers", "Collection of timeline markers"); | RNA_def_struct_ui_text(srna, "Timeline Markers", "Collection of timeline markers"); | ||||
| func = RNA_def_function(srna, "new", "rna_TimeLine_add"); | func = RNA_def_function(srna, "new", "rna_TimeLine_add"); | ||||
| RNA_def_function_ui_description(func, "Add a keyframe to the curve"); | RNA_def_function_ui_description(func, "Add a keyframe to the curve"); | ||||
| parm = RNA_def_string(func, "name", "Marker", 0, "", "New name for the marker (not unique)"); | parm = RNA_def_string(func, "name", "Marker", 0, "", "New name for the marker (not unique)"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED); | RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); | ||||
| parm = RNA_def_int(func, "frame", 1, -MAXFRAME, MAXFRAME, "", "The frame for the new marker", -MAXFRAME, MAXFRAME); | parm = RNA_def_int(func, "frame", 1, -MAXFRAME, MAXFRAME, "", "The frame for the new marker", -MAXFRAME, MAXFRAME); | ||||
| parm = RNA_def_pointer(func, "marker", "TimelineMarker", "", "Newly created timeline marker"); | parm = RNA_def_pointer(func, "marker", "TimelineMarker", "", "Newly created timeline marker"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| func = RNA_def_function(srna, "remove", "rna_TimeLine_remove"); | func = RNA_def_function(srna, "remove", "rna_TimeLine_remove"); | ||||
| RNA_def_function_ui_description(func, "Remove a timeline marker"); | RNA_def_function_ui_description(func, "Remove a timeline marker"); | ||||
| RNA_def_function_flag(func, FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_REPORTS); | ||||
| parm = RNA_def_pointer(func, "marker", "TimelineMarker", "", "Timeline marker to remove"); | parm = RNA_def_pointer(func, "marker", "TimelineMarker", "", "Timeline marker to remove"); | ||||
| RNA_def_property_flag(parm, PROP_REQUIRED | PROP_NEVER_NULL | PROP_RNAPTR); | RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR); | ||||
| RNA_def_property_clear_flag(parm, PROP_THICK_WRAP); | RNA_def_parameter_clear_flags(parm, PROP_THICK_WRAP, 0); | ||||
| func = RNA_def_function(srna, "clear", "rna_TimeLine_clear"); | func = RNA_def_function(srna, "clear", "rna_TimeLine_clear"); | ||||
| RNA_def_function_ui_description(func, "Remove all timeline markers"); | RNA_def_function_ui_description(func, "Remove all timeline markers"); | ||||
| } | } | ||||
| /* scene.keying_sets */ | /* scene.keying_sets */ | ||||
| static void rna_def_scene_keying_sets(BlenderRNA *brna, PropertyRNA *cprop) | static void rna_def_scene_keying_sets(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| { | { | ||||
| Show All 10 Lines | static void rna_def_scene_keying_sets(BlenderRNA *brna, PropertyRNA *cprop) | ||||
| /* Add Keying Set */ | /* Add Keying Set */ | ||||
| func = RNA_def_function(srna, "new", "rna_Scene_keying_set_new"); | func = RNA_def_function(srna, "new", "rna_Scene_keying_set_new"); | ||||
| RNA_def_function_ui_description(func, "Add a new Keying Set to Scene"); | RNA_def_function_ui_description(func, "Add a new Keying Set to Scene"); | ||||
| RNA_def_function_flag(func, FUNC_USE_REPORTS); | RNA_def_function_flag(func, FUNC_USE_REPORTS); | ||||
| /* name */ | /* name */ | ||||
| RNA_def_string(func, "idname", "KeyingSet", 64, "IDName", "Internal identifier of Keying Set"); | RNA_def_string(func, "idname", "KeyingSet", 64, "IDName", "Internal identifier of Keying Set"); | ||||
| RNA_def_string(func, "name", "KeyingSet", 64, "Name", "User visible name of Keying Set"); | RNA_def_string(func, "name", "KeyingSet", 64, "Name", "User visible name of Keying Set"); | ||||
| /* returns the new KeyingSet */ | /* returns the new KeyingSet */ | ||||
| parm = RNA_def_pointer(func, "keyingset", "KeyingSet", "", "Newly created Keying Set"); | parm = RNA_def_pointer(func, "keyingset", "KeyingSet", "", "Newly created Keying Set"); | ||||
| RNA_def_function_return(func, parm); | RNA_def_function_return(func, parm); | ||||
| prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | prop = RNA_def_property(srna, "active", PROP_POINTER, PROP_NONE); | ||||
| RNA_def_property_struct_type(prop, "KeyingSet"); | RNA_def_property_struct_type(prop, "KeyingSet"); | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE); | RNA_def_property_flag(prop, PROP_EDITABLE); | ||||
| RNA_def_property_pointer_funcs(prop, "rna_Scene_active_keying_set_get", | RNA_def_property_pointer_funcs(prop, "rna_Scene_active_keying_set_get", | ||||
| ▲ Show 20 Lines • Show All 467 Lines • ▼ Show 20 Lines | void RNA_def_scene(BlenderRNA *brna) | ||||
| prop = RNA_def_property(srna, "game_settings", PROP_POINTER, PROP_NONE); | prop = RNA_def_property(srna, "game_settings", PROP_POINTER, PROP_NONE); | ||||
| RNA_def_property_flag(prop, PROP_NEVER_NULL); | RNA_def_property_flag(prop, PROP_NEVER_NULL); | ||||
| RNA_def_property_pointer_sdna(prop, NULL, "gm"); | RNA_def_property_pointer_sdna(prop, NULL, "gm"); | ||||
| RNA_def_property_struct_type(prop, "SceneGameData"); | RNA_def_property_struct_type(prop, "SceneGameData"); | ||||
| RNA_def_property_ui_text(prop, "Game Data", ""); | RNA_def_property_ui_text(prop, "Game Data", ""); | ||||
| /* Statistics */ | /* Statistics */ | ||||
| func = RNA_def_function(srna, "statistics", "ED_info_stats_string"); | func = RNA_def_function(srna, "statistics", "ED_info_stats_string"); | ||||
| prop = RNA_def_string(func, "statistics", NULL, 0, "Statistics", ""); | parm = RNA_def_string(func, "statistics", NULL, 0, "Statistics", ""); | ||||
| RNA_def_function_return(func, prop); | RNA_def_function_return(func, parm); | ||||
| /* Grease Pencil */ | /* Grease Pencil */ | ||||
| prop = RNA_def_property(srna, "grease_pencil", PROP_POINTER, PROP_NONE); | prop = RNA_def_property(srna, "grease_pencil", PROP_POINTER, PROP_NONE); | ||||
| RNA_def_property_pointer_sdna(prop, NULL, "gpd"); | RNA_def_property_pointer_sdna(prop, NULL, "gpd"); | ||||
| RNA_def_property_struct_type(prop, "GreasePencil"); | RNA_def_property_struct_type(prop, "GreasePencil"); | ||||
| RNA_def_property_flag(prop, PROP_EDITABLE | PROP_ID_REFCOUNT); | RNA_def_property_flag(prop, PROP_EDITABLE | PROP_ID_REFCOUNT); | ||||
| RNA_def_property_ui_text(prop, "Grease Pencil Data", "Grease Pencil data-block"); | RNA_def_property_ui_text(prop, "Grease Pencil Data", "Grease Pencil data-block"); | ||||
| RNA_def_property_update(prop, NC_GPENCIL | ND_DATA | NA_EDITED, NULL); | RNA_def_property_update(prop, NC_GPENCIL | ND_DATA | NA_EDITED, NULL); | ||||
| ▲ Show 20 Lines • Show All 62 Lines • Show Last 20 Lines | |||||