transform_snap_object: Do not use occlusion test when X-Ray is enabled.
This commit is contained in:
parent
58efa7d686
commit
6de656b4f2
|
@ -2467,7 +2467,11 @@ static short transform_snap_context_project_view3d_mixed_impl(
|
|||
const ARegion *ar = sctx->v3d_data.ar;
|
||||
const RegionView3D *rv3d = ar->regiondata;
|
||||
|
||||
if (snap_to_flag & SCE_SNAP_MODE_FACE || params->use_occlusion_test) {
|
||||
bool use_occlusion_test =
|
||||
params->use_occlusion_test &&
|
||||
!(sctx->v3d_data.v3d->shading.flag & V3D_SHADING_XRAY);
|
||||
|
||||
if (snap_to_flag & SCE_SNAP_MODE_FACE || use_occlusion_test) {
|
||||
float ray_start[3], ray_normal[3];
|
||||
|
||||
if (!ED_view3d_win_to_ray_ex(
|
||||
|
|
Loading…
Reference in New Issue