0
$\begingroup$

Im trying to translate a vertex in 3D space while it should snap to closest point if it finds one. I have tried with all the snapping parameters listed in the API can’t seem to make it work anyone has any idea? I have also forced to snapping mode with these lines:

  bpy.context.scene.tool_settings.snap_elements = {'VERTEX'}
  bpy.context.scene.tool_settings.snap_target = 'ACTIVE'
  bpy.context.scene.tool_settings.use_snap = True

enter image description here

$\endgroup$
0
$\begingroup$

Try what was answered in this thread:

https://blenderartists.org/t/can-a-modal-operator-use-snapping/1175190

$\endgroup$
  • $\begingroup$ I actually have a costum snap with ray_cast and kdtree implemented in my own operator but the performance is too slow when dealing with really big meshes and scenes that's the main reason why im trying to use the blender's snapping, but thx for the info $\endgroup$ – XIWEI ZHOU Oct 22 '19 at 7:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.