Skip to content
This repository was archived by the owner on Aug 27, 2022. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions api/cameracontrol.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ def connect_to_camera(self):
def capture_image(self, path):
print('Capturing image')
self.print_config('capturetarget')
file_path = self.camera.capture(gp.GP_CAPTURE_IMAGE)
# refresh images on camera
self.camera.wait_for_event(1000)
file_path = self.camera.capture(gp.GP_CAPTURE_IMAGE)
print('Camera file path: {0}/{1}'.format(file_path.folder, file_path.name))
file_jpg = str(file_path.name).replace('.CR2', '.JPG')
print('Copying image to', path)
Expand Down Expand Up @@ -127,9 +127,7 @@ def handle_message(self, msg):
if args.imgpath is not None:
try:
self.capture_image(args.imgpath)
print('chroma')
if args.chroma_sensitivity is not None and args.chroma_sensitivity > 0:
print('do chroma')
self.chroma_key_image(args.imgpath)
self.socket.send_string('Image captured')
if self.args.bsm:
Expand Down