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:
authorCampbell Barton <ideasman42@gmail.com>2017-06-12 13:59:54 +0300
committerCampbell Barton <ideasman42@gmail.com>2017-06-12 14:34:55 +0300
commitf52dc2f371923c22a974df7105245f7e0b8148ee (patch)
treebd65af657cf7f06fdb01ee953182562c69189fed /source/blender/editors/object/object_add.c
parent12bd960df9bb9d96477b9913df8aec6fc7d87f95 (diff)
Rename probe to light-probe
Probe is a real general term, the new name is used often in docs online.
Diffstat (limited to 'source/blender/editors/object/object_add.c')
-rw-r--r--source/blender/editors/object/object_add.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c
index 411f8eb7347..2649a6d6d69 100644
--- a/source/blender/editors/object/object_add.c
+++ b/source/blender/editors/object/object_add.c
@@ -45,7 +45,7 @@
#include "DNA_object_fluidsim.h"
#include "DNA_object_force.h"
#include "DNA_object_types.h"
-#include "DNA_probe_types.h"
+#include "DNA_lightprobe_types.h"
#include "DNA_scene_types.h"
#include "DNA_vfont_types.h"
#include "DNA_actuator_types.h"
@@ -152,11 +152,11 @@ static EnumPropertyItem field_type_items[] = {
{0, NULL, 0, NULL, NULL}
};
-/* copy from rna_probe.c */
-static EnumPropertyItem probe_type_items[] = {
- {PROBE_CUBE, "CUBE", ICON_MESH_UVSPHERE, "Sphere", ""},
- // {PROBE_PLANAR, "PLANAR", ICON_MESH_PLANE, "Planar", ""},
- // {PROBE_IMAGE, "IMAGE", ICON_NONE, "Image", ""},
+/* copy from rna_lightprobe.c */
+static EnumPropertyItem lightprobe_type_items[] = {
+ {LIGHTPROBE_TYPE_CUBE, "CUBE", ICON_MESH_UVSPHERE, "Sphere", ""},
+ // {LIGHTPROBE_TYPE_PLANAR, "PLANAR", ICON_MESH_PLANE, "Planar", ""},
+ // {LIGHTPROBE_TYPE_IMAGE, "IMAGE", ICON_NONE, "Image", ""},
{0, NULL, 0, NULL, NULL}
};
@@ -512,10 +512,10 @@ void OBJECT_OT_add(wmOperatorType *ot)
/********************** Add Probe Operator **********************/
/* for object add operator */
-static int probe_add_exec(bContext *C, wmOperator *op)
+static int lightprobe_add_exec(bContext *C, wmOperator *op)
{
Object *ob;
- Probe *probe;
+ LightProbe *probe;
int type;
bool enter_editmode;
unsigned int layer;
@@ -529,11 +529,11 @@ static int probe_add_exec(bContext *C, wmOperator *op)
type = RNA_enum_get(op->ptr, "type");
dia = RNA_float_get(op->ptr, "radius");
- const char *name = CTX_DATA_(BLT_I18NCONTEXT_ID_OBJECT, "Probe");
- ob = ED_object_add_type(C, OB_PROBE, name, loc, rot, false, layer);
+ const char *name = CTX_DATA_(BLT_I18NCONTEXT_ID_OBJECT, "LightProbe");
+ ob = ED_object_add_type(C, OB_LIGHTPROBE, name, loc, rot, false, layer);
BKE_object_obdata_size_init(ob, dia);
- probe = (Probe *)ob->data;
+ probe = (LightProbe *)ob->data;
probe->type = type;
DEG_relations_tag_update(CTX_data_main(C));
@@ -541,22 +541,22 @@ static int probe_add_exec(bContext *C, wmOperator *op)
return OPERATOR_FINISHED;
}
-void OBJECT_OT_probe_add(wmOperatorType *ot)
+void OBJECT_OT_lightprobe_add(wmOperatorType *ot)
{
/* identifiers */
- ot->name = "Add Probe";
- ot->description = "Add a probe object";
- ot->idname = "OBJECT_OT_probe_add";
+ ot->name = "Add Light Probe";
+ ot->description = "Add a light probe object";
+ ot->idname = "OBJECT_OT_lightprobe_add";
/* api callbacks */
- ot->exec = probe_add_exec;
+ ot->exec = lightprobe_add_exec;
ot->poll = ED_operator_objectmode;
/* flags */
ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
/* properties */
- ot->prop = RNA_def_enum(ot->srna, "type", probe_type_items, 0, "Type", "");
+ ot->prop = RNA_def_enum(ot->srna, "type", lightprobe_type_items, 0, "Type", "");
ED_object_add_unit_props(ot);
ED_object_add_generic_props(ot, true);