Skip to content

Commit bcd3d86

Browse files
author
David Miguel Susano Pinto
committed
PiCamera: use ROI field names instead of tuple index for readability
1 parent 8f631d7 commit bcd3d86

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

microscope/cameras/picamera.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ def soft_trigger(self):
267267
self.camera.capture(output, format="yuv", use_video_port=False)
268268
self._queue.put(
269269
output.array[
270-
self.roi[1] : self.roi[1] + self.roi[3],
271-
self.roi[0] : self.roi[0] + self.roi[2],
270+
self.roi.top : self.roi.top + self.roi.height,
271+
self.roi.left : self.roi.left + self.roi.width,
272272
0,
273273
]
274274
)

0 commit comments

Comments
 (0)