save figures from matplotlib
[imago.git] / imago_pack / gridf.py
index dfb1e86..3c64720 100644 (file)
@@ -30,9 +30,9 @@ def job_4(x, y, w, z, im_l, v1, v2, h1, h2, dv, dh, size):
     h2 = (h2[0] + z * dh, h2[1] + z)
     return (distance(im_l, get_grid([v1, v2], [h1, h2], size), size))
 
-def find(lines, size, l1, l2, bounds, hough, show_all, do_something):
-    l1 = line_from_angl_dist(l1, size)
-    l2 = line_from_angl_dist(l2, size)
+def find(lines, size, l1, l2, bounds, hough, show_all, do_something, logger):
+    logger("finding the grid")
+
     v1 = V(*l1[0]) - V(*l1[1])
     v2 = V(*l2[0]) - V(*l2[1])
     a, b, c, d = [V(*a) for a in bounds]
@@ -98,6 +98,7 @@ def find(lines, size, l1, l2, bounds, hough, show_all, do_something):
             im_t_d.line(l, width=1, fill=(0, 255, 0))
 
         do_something(im_t, "lines and grid")
+#
 ###
 
     return grid, grid_lines