Commit 8dacbeb1 authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

fixed 2 bugs in python samples (crash in camshift and running samples from within the demo)

parent fd69c8b3
......@@ -58,7 +58,7 @@ class App(object):
ret, self.frame = self.cam.read()
vis = self.frame.copy()
hsv = cv2.cvtColor(self.frame, cv2.COLOR_BGR2HSV)
mask = cv2.inRange(hsv, np.array((0, 60, 32)), np.array((180, 255, 255)))
mask = cv2.inRange(hsv, np.array((0., 60., 32.)), np.array((180., 255., 255.)))
if self.selection:
x0, y0, x1, y1 = self.selection
......
......@@ -141,7 +141,7 @@ class App:
def on_run(self, *args):
cmd = self.cmd_entry.get()
print 'running:', cmd
Popen(cmd, shell=True)
Popen("python " + cmd, shell=True)
def run(self):
tk.mainloop()
......
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