From 12c70e3bbccf6e7953ef9f28b1a8e0f9777a87f0 Mon Sep 17 00:00:00 2001 From: tobias Date: Fri, 27 Jun 2025 15:23:27 +0200 Subject: [PATCH] Finish 2.2.2 exercise 3 --- CV-App/algorithms/invis_cloak.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/CV-App/algorithms/invis_cloak.py b/CV-App/algorithms/invis_cloak.py index c3367d1..82c4c9d 100644 --- a/CV-App/algorithms/invis_cloak.py +++ b/CV-App/algorithms/invis_cloak.py @@ -62,12 +62,15 @@ class InvisCloak (Algorithm): print("A Mouse click happend! at position", x, y) # Stores the current image to data folder - cv2.imwrite(f"results/{datetime.datetime.now().strftime('%Y-%m-%d_%H:%M:%S')}_captured_image.png", + cv2.imwrite(f"results/{datetime.datetime.now().strftime('%Y-%m-%d_%H:%M:%S')}_original_image.png", self.picture_buffer[4]) # Create RGB histogram self._221_RGB(self.middle_value_picture) + # Create HSV histogram + self._222_HSV(self.middle_value_picture) + def _plotNoise(self, img, name:str): height, width = np.array(img.shape[:2]) @@ -150,7 +153,7 @@ class InvisCloak (Algorithm): Hier steht Ihr Code zu Aufgabe 2.2.2 (HSV) - Histogrammberechnung und Analyse im HSV-Raum """ - pass + self._221_RGB(cv2.cvtColor(img, cv2.COLOR_BGR2HSV), "hsv") def _23_SegmentUndBildmodifizierung (self, img):