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>2018-05-08 15:18:09 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-05-08 16:35:04 +0300
commita48186c5d74b3d353c5c65cd4a930dd98cc9a603 (patch)
treec49fd2af2aaac151c5fd1265e414392617043253 /source/blender/editors/mesh
parent53a56b7b6c169b21df475ae94795208501581489 (diff)
Orientation for 3D cursor
Currently set when setting the cursor location, optionally used as an orientation type. Intended for use by tools too. See: D3208
Diffstat (limited to 'source/blender/editors/mesh')
-rw-r--r--source/blender/editors/mesh/editmesh_bisect.c2
-rw-r--r--source/blender/editors/mesh/editmesh_extrude.c2
-rw-r--r--source/blender/editors/mesh/editmesh_extrude_screw.c2
-rw-r--r--source/blender/editors/mesh/editmesh_extrude_spin.c2
-rw-r--r--source/blender/editors/mesh/editmesh_polybuild.c2
-rw-r--r--source/blender/editors/mesh/editmesh_tools.c6
6 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/mesh/editmesh_bisect.c b/source/blender/editors/mesh/editmesh_bisect.c
index ac8c1f16477..ee06f7abd2b 100644
--- a/source/blender/editors/mesh/editmesh_bisect.c
+++ b/source/blender/editors/mesh/editmesh_bisect.c
@@ -243,7 +243,7 @@ static int mesh_bisect_exec(bContext *C, wmOperator *op)
RNA_property_float_get_array(op->ptr, prop_plane_co, plane_co);
}
else {
- copy_v3_v3(plane_co, ED_view3d_cursor3d_get(scene, v3d));
+ copy_v3_v3(plane_co, ED_view3d_cursor3d_get(scene, v3d)->location);
RNA_property_float_set_array(op->ptr, prop_plane_co, plane_co);
}
diff --git a/source/blender/editors/mesh/editmesh_extrude.c b/source/blender/editors/mesh/editmesh_extrude.c
index ca49d4e5448..41053d423de 100644
--- a/source/blender/editors/mesh/editmesh_extrude.c
+++ b/source/blender/editors/mesh/editmesh_extrude.c
@@ -973,7 +973,7 @@ static int edbm_dupli_extrude_cursor_invoke(bContext *C, wmOperator *op, const w
BM_ELEM_SELECT, ofs);
}
else {
- const float *cursor = ED_view3d_cursor3d_get(vc.scene, vc.v3d);
+ const float *cursor = ED_view3d_cursor3d_get(vc.scene, vc.v3d)->location;
BMOperator bmop;
BMOIter oiter;
diff --git a/source/blender/editors/mesh/editmesh_extrude_screw.c b/source/blender/editors/mesh/editmesh_extrude_screw.c
index debab7edf21..3be8ab9c2e4 100644
--- a/source/blender/editors/mesh/editmesh_extrude_screw.c
+++ b/source/blender/editors/mesh/editmesh_extrude_screw.c
@@ -148,7 +148,7 @@ static int edbm_screw_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(
PropertyRNA *prop;
prop = RNA_struct_find_property(op->ptr, "center");
if (!RNA_property_is_set(op->ptr, prop)) {
- RNA_property_float_set_array(op->ptr, prop, ED_view3d_cursor3d_get(scene, v3d));
+ RNA_property_float_set_array(op->ptr, prop, ED_view3d_cursor3d_get(scene, v3d)->location);
}
if (rv3d) {
prop = RNA_struct_find_property(op->ptr, "axis");
diff --git a/source/blender/editors/mesh/editmesh_extrude_spin.c b/source/blender/editors/mesh/editmesh_extrude_spin.c
index a4106ebcde1..4195f7daef3 100644
--- a/source/blender/editors/mesh/editmesh_extrude_spin.c
+++ b/source/blender/editors/mesh/editmesh_extrude_spin.c
@@ -487,7 +487,7 @@ static int edbm_spin_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(e
PropertyRNA *prop;
prop = RNA_struct_find_property(op->ptr, "center");
if (!RNA_property_is_set(op->ptr, prop)) {
- RNA_property_float_set_array(op->ptr, prop, ED_view3d_cursor3d_get(scene, v3d));
+ RNA_property_float_set_array(op->ptr, prop, ED_view3d_cursor3d_get(scene, v3d)->location);
}
if (rv3d) {
prop = RNA_struct_find_property(op->ptr, "axis");
diff --git a/source/blender/editors/mesh/editmesh_polybuild.c b/source/blender/editors/mesh/editmesh_polybuild.c
index dff501ece13..e8bcfb5eb08 100644
--- a/source/blender/editors/mesh/editmesh_polybuild.c
+++ b/source/blender/editors/mesh/editmesh_polybuild.c
@@ -89,7 +89,7 @@ static int edbm_polybuild_face_at_cursor_invoke(
if (ele_act == NULL || ele_act->head.htype == BM_FACE) {
/* Just add vert */
- copy_v3_v3(center, ED_view3d_cursor3d_get(vc.scene, vc.v3d));
+ copy_v3_v3(center, ED_view3d_cursor3d_get(vc.scene, vc.v3d)->location);
mul_v3_m4v3(center, vc.obedit->obmat, center);
ED_view3d_win_to_3d_int(vc.v3d, vc.ar, center, event->mval, center);
mul_m4_v3(vc.obedit->imat, center);
diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c
index e6eec41e4d6..219c3acd2f7 100644
--- a/source/blender/editors/mesh/editmesh_tools.c
+++ b/source/blender/editors/mesh/editmesh_tools.c
@@ -2608,7 +2608,7 @@ static bool merge_target(
const float *vco = NULL;
if (use_cursor) {
- vco = ED_view3d_cursor3d_get(scene, v3d);
+ vco = ED_view3d_cursor3d_get(scene, v3d)->location;
copy_v3_v3(co, vco);
invert_m4_m4(ob->imat, ob->obmat);
mul_m4_v3(ob->imat, co);
@@ -5469,9 +5469,9 @@ static void sort_bmelem_flag(
float fact = reverse ? -1.0 : 1.0;
if (v3d && v3d->localvd)
- copy_v3_v3(cur, v3d->cursor);
+ copy_v3_v3(cur, v3d->cursor.location);
else
- copy_v3_v3(cur, scene->cursor);
+ copy_v3_v3(cur, scene->cursor.location);
invert_m4_m4(mat, ob->obmat);
mul_m4_v3(mat, cur);