diff options
| author | Thibaut Horel <thibaut.horel@gmail.com> | 2012-02-15 15:25:26 -0800 |
|---|---|---|
| committer | Thibaut Horel <thibaut.horel@gmail.com> | 2012-02-15 15:25:26 -0800 |
| commit | 83c5e1cfd0b4b3546dd13ebf9010736ac9410ffa (patch) | |
| tree | b8fe96d0a3bfa8d1566d51a362ff2fe1b5a2f6f4 /data | |
| parent | 87dcc50bc1f777b63f5956286d94d3ea8b9592a6 (diff) | |
| download | kinect-83c5e1cfd0b4b3546dd13ebf9010736ac9410ffa.tar.gz | |
Change faces.py to save the rectangle region.
Diffstat (limited to 'data')
| -rwxr-xr-x | data/faces.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/data/faces.py b/data/faces.py index 528bfa0..8e60307 100755 --- a/data/faces.py +++ b/data/faces.py @@ -35,9 +35,9 @@ for line in sk_file: y1 = max(int(limbs[j1][1] - r),0) x2 = min(int(x1 + 2*r), img.width) y2 = min(int(y1 + 3*r), img.height) - - cv.Rectangle(img,(x1,y1),(x2,y2),(0,255,0),3,8,0) - #cv.SaveImage(out_dir+str(run)+"-"+str(frame)+'.jpg',img) + sub = cv.GetSubRect(img,(x1,y1,x2-x1,y2-y1)) + #cv.Rectangle(img,(x1,y1),(x2,y2),(0,255,0),3,8,0) + cv.SaveImage(out_dir+str(run)+"-"+str(frame)+'.jpg',sub) cv.ShowImage('video', img) cv.WaitKey(5) pframe = frame |
