summaryrefslogtreecommitdiff
path: root/opencv-qt-integration-2
diff options
context:
space:
mode:
Diffstat (limited to 'opencv-qt-integration-2')
-rw-r--r--opencv-qt-integration-2/python/ImageApp.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/opencv-qt-integration-2/python/ImageApp.py b/opencv-qt-integration-2/python/ImageApp.py
index 7745711..afa00b1 100644
--- a/opencv-qt-integration-2/python/ImageApp.py
+++ b/opencv-qt-integration-2/python/ImageApp.py
@@ -46,7 +46,8 @@ class ImageApp(QWidget):
# Setup main layout
self.main_layout = QHBoxLayout()
self.main_layout.addWidget(self.image_label)
- self.main_layout.addLayout(self.buttons_layout)
+ if self.original_img is not None:
+ self.main_layout.addLayout(self.buttons_layout)
self.setLayout(self.main_layout)
self.setWindowTitle("Image Processing with Qt and OpenCV")