Commit c1857e73 authored by sumpfralle's avatar sumpfralle

fixed "direction" issue for zero-length lines


git-svn-id: https://pycam.svn.sourceforge.net/svnroot/pycam/trunk@858 bbaffbd6-741e-11dd-a85d-61de82d9cad9
parent 8d452189
......@@ -651,6 +651,9 @@ def draw_direction_cone(p1, p2):
distance = p2.sub(p1)
length = distance.norm
direction = distance.normalized()
if direction is None:
# zero-length line
return
cone_radius = length / 30
cone_length = length / 10
# move the cone to the middle of the line
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment