aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThéo de la Hogue2024-07-01 09:50:07 +0200
committerThéo de la Hogue2024-07-01 09:50:07 +0200
commit8ada0d22823eee73903c4f495cc2d946f8f5e884 (patch)
tree36f0b4b0eee9494d5c49311472f122504ec4f766
parentd139e6a0028678a3484e5537819f69909650bf96 (diff)
downloadargaze-8ada0d22823eee73903c4f495cc2d946f8f5e884.zip
argaze-8ada0d22823eee73903c4f495cc2d946f8f5e884.tar.gz
argaze-8ada0d22823eee73903c4f495cc2d946f8f5e884.tar.bz2
argaze-8ada0d22823eee73903c4f495cc2d946f8f5e884.tar.xz
Don't get image shape if no image is read.
-rw-r--r--src/argaze/utils/contexts/OpenCV.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/argaze/utils/contexts/OpenCV.py b/src/argaze/utils/contexts/OpenCV.py
index c2361a8..111ed8e 100644
--- a/src/argaze/utils/contexts/OpenCV.py
+++ b/src/argaze/utils/contexts/OpenCV.py
@@ -152,10 +152,10 @@ class Movie(ArFeatures.PostProcessingContext):
success, image = self.__movie.read()
- video_height, video_width, _ = image.shape
-
if success:
+ video_height, video_width, _ = image.shape
+
# Refresh once
self.__refresh = False