diff options
author | Sebastian Parborg <darkdefende@gmail.com> | 2019-04-09 13:29:02 +0300 |
---|---|---|
committer | Sebastian Parborg <darkdefende@gmail.com> | 2019-04-09 13:29:02 +0300 |
commit | cc74020b5ac7d974e91279e23efc80141c229b3c (patch) | |
tree | b48fe326706a8974f30385f8d861bcdd2bda0e7e /source/blender/editors/mesh | |
parent | f55026d46861a3cb0108ad3f7bab8ed0610f660d (diff) |
Fix T62114: Wireframe mode selection: selects backside objects when clicking frontside object in 3d-window
Now the depth order of objects when trying to select them is only used when not in X-ray mode.
Before, this was only the case in wireframe mode regardless of X-ray settings.
I've also unified the usage of V3D_XRAY and XRAY_FLAG as they were basically copies of each other.
Reviewed By: Clément
Differential Revision: http://developer.blender.org/D4504
Diffstat (limited to 'source/blender/editors/mesh')
-rw-r--r-- | source/blender/editors/mesh/editmesh_select.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/editors/mesh/editmesh_select.c b/source/blender/editors/mesh/editmesh_select.c index 1855eeab944..c04fe58c12e 100644 --- a/source/blender/editors/mesh/editmesh_select.c +++ b/source/blender/editors/mesh/editmesh_select.c @@ -215,7 +215,7 @@ bool EDBM_backbuf_border_init( { uint *buf, *dr, buf_len; - if (vc->obedit == NULL || !V3D_IS_ZBUF(vc->v3d)) { + if (vc->obedit == NULL || XRAY_ENABLED(vc->v3d)) { return false; } @@ -292,7 +292,7 @@ bool EDBM_backbuf_border_mask_init(ViewContext *vc, const int mcords[][2], short return false; } } - else if (!V3D_IS_ZBUF(vc->v3d)) { + else if (XRAY_ENABLED(vc->v3d)) { return false; } @@ -342,7 +342,7 @@ bool EDBM_backbuf_circle_init( return false; } } - else if (!V3D_IS_ZBUF(vc->v3d)) { + else if (XRAY_ENABLED(vc->v3d)) { return false; } @@ -464,7 +464,7 @@ BMVert *EDBM_vert_find_nearest_ex( { BMesh *bm = vc->em->bm; - if (V3D_IS_ZBUF(vc->v3d)) { + if (!XRAY_ENABLED(vc->v3d)) { uint dist_px = (uint)ED_view3d_backbuf_sample_size_clamp(vc->ar, *r_dist); unsigned int index; BMVert *eve; @@ -655,7 +655,7 @@ BMEdge *EDBM_edge_find_nearest_ex( { BMesh *bm = vc->em->bm; - if (V3D_IS_ZBUF(vc->v3d)) { + if (!XRAY_ENABLED(vc->v3d)) { uint dist_px = (uint)ED_view3d_backbuf_sample_size_clamp(vc->ar, *r_dist); unsigned int index; BMEdge *eed; @@ -825,7 +825,7 @@ BMFace *EDBM_face_find_nearest_ex( { BMesh *bm = vc->em->bm; - if (V3D_IS_ZBUF(vc->v3d)) { + if (!XRAY_ENABLED(vc->v3d)) { float dist_test = 0.0f; unsigned int index; BMFace *efa; |