Commit ff41355e authored by sumpfralle's avatar sumpfralle

small code simplification for the PushCutter (done by lode)


git-svn-id: https://pycam.svn.sourceforge.net/svnroot/pycam/trunk@407 bbaffbd6-741e-11dd-a85d-61de82d9cad9
parent 7bd8abf4
......@@ -99,19 +99,19 @@ def get_free_paths_triangles(model, cutter, p1, p2):
hits.sort(Hit.cmp)
c = None
t = []
count = 0
points = []
for h in hits:
if h.dir == forward:
if len(t)==0:
if count == 0:
if h.d >= 0:
if len(points) == 0:
points.append(p1)
points.append(h.cl)
t.append(h.t)
count += 1
else:
t.remove(h.t)
if len(t)==0:
count -= 1
if count == 0:
if h.d <= xyz_dist:
points.append(h.cl)
......
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