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>2021-01-20 08:57:02 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-01-20 09:07:20 +0300
commit908b383b7d2199c0c614d085ff65a03eb7852274 (patch)
tree955c797b1100c3af5232bbba4a00f711a33f3eee /source/blender/editors/uvedit/uvedit_intern.h
parent9f337bef80d2e7259a9e7fec0b8ec8cd807881ae (diff)
UV: tweak face select behavior
When the mouse cursor is inside the UV face, extend the selection threshold. This means when zoomed in, a face can always be selected when the cursor is inside it. In the case of multiple overlapping faces - the face with the closest center is used. ---- Prior to 246efd7286f6187e4dd4b3edcc79cccb1746bb1d, the UV selection threshold was scaled by the zoom level, so selecting a face when zoomed in close would often often select faces even when the on-screen center was outside the intended threshold. Having a zoom-independent threshold may require more precision than users are used to. This change addresses this.
Diffstat (limited to 'source/blender/editors/uvedit/uvedit_intern.h')
-rw-r--r--source/blender/editors/uvedit/uvedit_intern.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/editors/uvedit/uvedit_intern.h b/source/blender/editors/uvedit/uvedit_intern.h
index 45d65e7070e..cd8fbd00316 100644
--- a/source/blender/editors/uvedit/uvedit_intern.h
+++ b/source/blender/editors/uvedit/uvedit_intern.h
@@ -93,10 +93,21 @@ bool uv_find_nearest_edge_multi(struct Scene *scene,
const float co[2],
struct UvNearestHit *hit);
+bool uv_find_nearest_face_ex(struct Scene *scene,
+ struct Object *obedit,
+ const float co[2],
+ struct UvNearestHit *hit,
+ const bool only_in_face);
bool uv_find_nearest_face(struct Scene *scene,
struct Object *obedit,
const float co[2],
struct UvNearestHit *hit);
+bool uv_find_nearest_face_multi_ex(struct Scene *scene,
+ struct Object **objects,
+ const uint objects_len,
+ const float co[2],
+ struct UvNearestHit *hit,
+ const bool only_in_face);
bool uv_find_nearest_face_multi(struct Scene *scene,
struct Object **objects,
const uint objects_len,