Skip to content

Commit

Permalink
Changed screenshots file
Browse files Browse the repository at this point in the history
  • Loading branch information
AurelienChagnon committed Aug 27, 2017
1 parent 0977972 commit 45fe262
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions AutomaticPatch/Camera/Camera.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ def save_img(self):
Save a screenshot
:return:
"""
path = './{i}/screenshots/'.format(i=self.camera_name)
path = './screenshots/'
# Check if path exist, creates it if not
if not os.path.exists(os.path.dirname(path)):
try:
Expand All @@ -106,7 +106,7 @@ def save_img(self):
# Translate the image as a 8bit image
img = self.frame
n_img = len(os.listdir(path))+1
cv2.imwrite('./{i}/screenshots/screenshot{n}.jpg'.format(i=self.camera_name, n=n_img), img)
cv2.imwrite('./screenshots/screenshot{n}.jpg'.format(n=n_img), img)
pass

def switch_mouse_callback(self):
Expand Down

0 comments on commit 45fe262

Please sign in to comment.