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:
authorDalai Felinto <dfelinto@gmail.com>2014-06-12 05:46:35 +0400
committerDalai Felinto <dfelinto@gmail.com>2014-06-12 05:49:30 +0400
commitaed67dc8a43fe12f4b47a24fb0c23be798ae05b9 (patch)
tree58ade97a7f4b4a15fd5663a8ba61e5b85b827e73
parent990eb2d7378bb529cff6a1ea1fbdbb802bdadf2d (diff)
Bake-API: Set Custom Cage to be Cage Object
Suggestion by Andy Davies (metalliandy) to conform with industry standard (custom cage is something else apparently) Note: this is the last bake related commit I plan for 2.71/rc (unless everyone agrees that we could squeeze in D546 - custom UVs, which would be really nice to add for 2.71 scripters) Note 2: I'll update the wiki docs shortly
-rw-r--r--intern/cycles/blender/addon/ui.py2
-rw-r--r--source/blender/editors/object/object_bake_api.c6
-rw-r--r--source/blender/makesrna/intern/rna_scene.c4
3 files changed, 6 insertions, 6 deletions
diff --git a/intern/cycles/blender/addon/ui.py b/intern/cycles/blender/addon/ui.py
index 1797f29365e..a6a3501b912 100644
--- a/intern/cycles/blender/addon/ui.py
+++ b/intern/cycles/blender/addon/ui.py
@@ -1263,7 +1263,7 @@ class CyclesRender_PT_bake(CyclesButtonsPanel, Panel):
sub.prop(cbk, "use_cage", text="Cage")
if cbk.use_cage:
sub.prop(cbk, "cage_extrusion", text="Cage Extrusion")
- sub.prop_search(cbk, "custom_cage", scene, "objects")
+ sub.prop_search(cbk, "cage_object", scene, "objects")
else:
sub.prop(cbk, "cage_extrusion", text="Ray Distance")
diff --git a/source/blender/editors/object/object_bake_api.c b/source/blender/editors/object/object_bake_api.c
index b69de3d0b81..de709a4f03d 100644
--- a/source/blender/editors/object/object_bake_api.c
+++ b/source/blender/editors/object/object_bake_api.c
@@ -1006,7 +1006,7 @@ static void bake_init_api_data(wmOperator *op, bContext *C, BakeAPIRender *bkr)
bkr->height = RNA_int_get(op->ptr, "height");
bkr->identifier = "";
- RNA_string_get(op->ptr, "cage", bkr->custom_cage);
+ RNA_string_get(op->ptr, "cage_object", bkr->custom_cage);
if ((!is_save_internal) && bkr->is_automatic_name) {
PropertyRNA *prop = RNA_struct_find_property(op->ptr, "type");
@@ -1150,7 +1150,7 @@ static void bake_set_props(wmOperator *op, Scene *scene)
RNA_property_float_set(op->ptr, prop, bake->cage_extrusion);
}
- prop = RNA_struct_find_property(op->ptr, "cage");
+ prop = RNA_struct_find_property(op->ptr, "cage_object");
if (!RNA_property_is_set(op->ptr, prop)) {
RNA_property_string_set(op->ptr, prop, bake->cage);
}
@@ -1266,7 +1266,7 @@ void OBJECT_OT_bake(wmOperatorType *ot)
"Bake shading on the surface of selected objects to the active object");
RNA_def_float(ot->srna, "cage_extrusion", 0.0, 0.0, 1.0, "Cage Extrusion",
"Distance to use for the inward ray cast when using selected to active", 0.0, 1.0);
- RNA_def_string(ot->srna, "cage", NULL, MAX_NAME, "Custom Cage",
+ RNA_def_string(ot->srna, "cage_object", NULL, MAX_NAME, "Cage Object",
"Object to use as cage, instead of calculating the cage from the active object with cage extrusion");
RNA_def_enum(ot->srna, "normal_space", normal_space_items, R_BAKE_SPACE_TANGENT, "Normal Space",
"Choose normal space for baking");
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c
index 92c4d3dd204..bcdb469dd85 100644
--- a/source/blender/makesrna/intern/rna_scene.c
+++ b/source/blender/makesrna/intern/rna_scene.c
@@ -3218,9 +3218,9 @@ static void rna_def_bake_data(BlenderRNA *brna)
RNA_def_struct_nested(brna, srna, "RenderSettings");
RNA_def_struct_ui_text(srna, "Bake Data", "Bake data for a Scene datablock");
- prop = RNA_def_property(srna, "custom_cage", PROP_STRING, PROP_NONE);
+ prop = RNA_def_property(srna, "cage_object", PROP_STRING, PROP_NONE);
RNA_def_property_string_sdna(prop, NULL, "cage");
- RNA_def_property_ui_text(prop, "Custom Cage", "Object to use as cage "
+ RNA_def_property_ui_text(prop, "Cage Object", "Object to use as cage "
"instead of calculating the cage from the active object with cage extrusion");
RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL);