Fix T76894: Disable clipping region selection in material/rendered mode

In this case the draw engine isn't responsible for the selection, but
the editor is.

Reviewed By: Clément Foucault

Differential Revision: https://developer.blender.org/D7955
This commit is contained in:
Jeroen Bakker 2020-06-08 12:47:17 +02:00
parent 84a5bd9135
commit 4622434c34
Notes: blender-bot 2023-02-14 09:33:11 +01:00
Referenced by issue #77348, Blender LTS: Maintenance Task 2.83
Referenced by issue #76894, Mesh cage appears outside of Clipping Region in Edit mode in Material and Render preview
1 changed files with 3 additions and 1 deletions

View File

@ -319,7 +319,9 @@ BMVert *EDBM_vert_find_nearest_ex(ViewContext *vc,
else {
struct NearestVertUserData data = {{0}};
const struct NearestVertUserData_Hit *hit = NULL;
const eV3DProjTest clip_flag = V3D_PROJ_TEST_CLIP_DEFAULT;
const eV3DProjTest clip_flag = RV3D_CLIPPING_ENABLED(vc->v3d, vc->rv3d) ?
V3D_PROJ_TEST_CLIP_DEFAULT :
V3D_PROJ_TEST_CLIP_DEFAULT & ~V3D_PROJ_TEST_CLIP_BB;
BMesh *prev_select_bm = NULL;
static struct {