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:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2018-05-08 16:57:20 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-05-08 18:46:20 +0300
commite6d11c6ce66f94549d1fe896c59b67564ae19d68 (patch)
treebabe12f8b03d92d1a43d880e044bca2394ecd118 /source/blender/makesrna
parent03dd109a84657ebf778dc3c25776f7a93cccf1ac (diff)
Collections: remove per collection and view layer engine overrides.
This will be handled by the new view layer override system which will store data elsewhere, removing the code already for easier refactoring.
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/RNA_access.h1
-rw-r--r--source/blender/makesrna/intern/rna_layer.c38
-rw-r--r--source/blender/makesrna/intern/rna_object.c25
-rw-r--r--source/blender/makesrna/intern/rna_ui_api.c10
4 files changed, 2 insertions, 72 deletions
diff --git a/source/blender/makesrna/RNA_access.h b/source/blender/makesrna/RNA_access.h
index 70a6759b4e8..c67106f437f 100644
--- a/source/blender/makesrna/RNA_access.h
+++ b/source/blender/makesrna/RNA_access.h
@@ -320,7 +320,6 @@ extern StructRNA RNA_Lattice;
extern StructRNA RNA_LatticeModifier;
extern StructRNA RNA_LatticePoint;
extern StructRNA RNA_LayerCollection;
-extern StructRNA RNA_LayerCollectionOverride;
extern StructRNA RNA_Library;
extern StructRNA RNA_LimitDistanceConstraint;
extern StructRNA RNA_LimitLocationConstraint;
diff --git a/source/blender/makesrna/intern/rna_layer.c b/source/blender/makesrna/intern/rna_layer.c
index c9728e82442..e64f5cf8b3e 100644
--- a/source/blender/makesrna/intern/rna_layer.c
+++ b/source/blender/makesrna/intern/rna_layer.c
@@ -94,7 +94,7 @@ static PointerRNA rna_SceneCollection_objects_get(CollectionPropertyIterator *it
{
ListBaseIterator *internal = &iter->internal.listbase;
- /* we are actually iterating a LinkData list, so override get */
+ /* we are actually iterating a LinkData list */
return rna_pointer_inherit_refine(&iter->parent, &RNA_Object, ((LinkData *)internal->link)->data);
}
@@ -810,7 +810,7 @@ static PointerRNA rna_ViewLayer_objects_get(CollectionPropertyIterator *iter)
{
ListBaseIterator *internal = &iter->internal.listbase;
- /* we are actually iterating a ObjectBase list, so override get */
+ /* we are actually iterating a ObjectBase list */
Base *base = (Base *)internal->link;
return rna_pointer_inherit_refine(&iter->parent, &RNA_Object, base->object);
}
@@ -996,22 +996,6 @@ static void rna_def_scene_collection(BlenderRNA *brna)
RNA_def_function_return(func, parm);
}
-static void rna_def_layer_collection_override(BlenderRNA *brna)
-{
- StructRNA *srna;
- PropertyRNA *prop;
-
- srna = RNA_def_struct(brna, "LayerCollectionOverride", NULL);
- RNA_def_struct_sdna(srna, "CollectionOverride");
- RNA_def_struct_ui_text(srna, "Collection Override", "Collection Override");
-
- prop = RNA_def_property(srna, "name", PROP_STRING, PROP_NONE);
- RNA_def_property_ui_text(prop, "Name", "Collection name");
- RNA_def_struct_name_property(srna, prop);
- RNA_def_property_update(prop, NC_SCENE | ND_LAYER_CONTENT, NULL);
-}
-
-
#ifdef WITH_CLAY_ENGINE
static void rna_def_view_layer_engine_settings_clay(BlenderRNA *brna)
{
@@ -1786,17 +1770,6 @@ static void rna_def_layer_collection(BlenderRNA *brna)
RNA_def_property_collection_funcs(prop, NULL, NULL, NULL, "rna_LayerCollection_objects_get", NULL, NULL, NULL, NULL);
RNA_def_property_ui_text(prop, "Objects", "All the objects directly or indirectly added to this collection (not including sub-collection objects)");
- prop = RNA_def_property(srna, "overrides", PROP_COLLECTION, PROP_NONE);
- RNA_def_property_collection_sdna(prop, NULL, "overrides", NULL);
- RNA_def_property_struct_type(prop, "LayerCollectionOverride");
- RNA_def_property_ui_text(prop, "Collection Overrides", "");
-
- /* Override settings */
- prop = RNA_def_property(srna, "engine_overrides", PROP_COLLECTION, PROP_NONE);
- RNA_def_property_collection_sdna(prop, NULL, "properties->data.group", NULL);
- RNA_def_property_struct_type(prop, "LayerCollectionSettings");
- RNA_def_property_ui_text(prop, "Collection Settings", "Override of engine specific render settings");
-
/* Functions */
func = RNA_def_function(srna, "move_above", "rna_LayerCollection_move_above");
RNA_def_function_ui_description(func, "Move collection after another");
@@ -2002,12 +1975,6 @@ void RNA_def_view_layer(BlenderRNA *brna)
RNA_def_property_struct_type(prop, "FreestyleSettings");
RNA_def_property_ui_text(prop, "Freestyle Settings", "");
- /* Override settings */
- prop = RNA_def_property(srna, "engine_overrides", PROP_COLLECTION, PROP_NONE);
- RNA_def_property_collection_sdna(prop, NULL, "properties->data.group", NULL);
- RNA_def_property_struct_type(prop, "ViewLayerSettings");
- RNA_def_property_ui_text(prop, "Layer Settings", "Override of engine specific render settings");
-
/* debug update routine */
func = RNA_def_function(srna, "update", "rna_ViewLayer_update_tagged");
RNA_def_function_flag(func, FUNC_USE_CONTEXT);
@@ -2025,7 +1992,6 @@ void RNA_def_view_layer(BlenderRNA *brna)
RNA_define_animate_sdna(false);
rna_def_scene_collection(brna);
rna_def_layer_collection(brna);
- rna_def_layer_collection_override(brna);
rna_def_object_base(brna);
RNA_define_animate_sdna(true);
/* *** Animated *** */
diff --git a/source/blender/makesrna/intern/rna_object.c b/source/blender/makesrna/intern/rna_object.c
index 68df1cae4aa..f2b71e20ab9 100644
--- a/source/blender/makesrna/intern/rna_object.c
+++ b/source/blender/makesrna/intern/rna_object.c
@@ -236,15 +236,6 @@ static int rna_Object_is_visible_get(PointerRNA *ptr)
return BKE_object_is_visible(ob, OB_VISIBILITY_CHECK_UNKNOWN_RENDER_MODE);
}
-static void rna_Object_collection_properties_begin(CollectionPropertyIterator *iter, PointerRNA *ptr)
-{
- Object *ob = ptr->data;
-
- if (ob->base_collection_properties != NULL) {
- rna_iterator_listbase_begin(iter, &ob->base_collection_properties->data.group, NULL);
- }
-}
-
static void rna_Object_matrix_local_get(PointerRNA *ptr, float values[16])
{
Object *ob = ptr->id.data;
@@ -2289,22 +2280,6 @@ static void rna_def_object(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Visible", "Visible to camera rays, set only on objects evaluated by depsgraph");
RNA_def_property_clear_flag(prop, PROP_EDITABLE);
- prop = RNA_def_property(srna, "collection_properties", PROP_COLLECTION, PROP_NONE);
- RNA_def_property_collection_sdna(prop, NULL, "base_collection_properties->data.group", NULL);
- RNA_def_property_collection_funcs(prop,
- "rna_Object_collection_properties_begin",
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL);
- RNA_def_property_struct_type(prop, "LayerCollectionSettings");
- RNA_def_property_flag(prop, PROP_NO_COMPARISON); /* XXX see T53800. */
- RNA_def_property_ui_text(prop, "Collection Settings",
- "Engine specific render settings to be overridden by collections");
-
/* anim */
rna_def_animdata_common(srna);
diff --git a/source/blender/makesrna/intern/rna_ui_api.c b/source/blender/makesrna/intern/rna_ui_api.c
index d980696c3ee..d61f6166889 100644
--- a/source/blender/makesrna/intern/rna_ui_api.c
+++ b/source/blender/makesrna/intern/rna_ui_api.c
@@ -1013,16 +1013,6 @@ void RNA_api_ui_layout(StructRNA *srna)
parm = RNA_def_pointer(func, "item", "KeyMapItem", "", "");
RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR);
- func = RNA_def_function(srna, "template_override_property", "uiTemplateOverrideProperty");
- parm = RNA_def_pointer(func, "collection_render_overrides", "AnyType", "", "");
- RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR);
- parm = RNA_def_pointer(func, "scene_collection_properties", "AnyType", "", "");
- RNA_def_parameter_flags(parm, PROP_NEVER_NULL, PARM_REQUIRED | PARM_RNAPTR);
- parm = RNA_def_string(func, "property", NULL, 0, "", "Identifier of property in collection_properties");
- RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
- api_ui_item_common(func);
- parm = RNA_def_string(func, "custom_template", NULL, 0, "", "Optional template to use for property");
-
func = RNA_def_function(srna, "template_component_menu", "uiTemplateComponentMenu");
RNA_def_function_ui_description(func, "Item. Display expanded property in a popup menu");
parm = RNA_def_pointer(func, "data", "AnyType", "", "Data from which to take property");