diff --git a/test/2024,9,10/main.py b/test/2024,9,10/main.py index 11a8fb4..9eae4cd 100644 --- a/test/2024,9,10/main.py +++ b/test/2024,9,10/main.py @@ -7,19 +7,24 @@ img = cv.imread("opencv_logo.png",cv.IMREAD_UNCHANGED) height,width,channel=img.shape # show infos +print(img.shape) print("height=\t",height) print("width=\t",width) -print("channel=\t",height) +print("channel=\t",channel) # split channels blue,green,red=cv.split(img) # show channels ## red channel -#cv.imshow("channel", red) +cv.namedWindow("red channel") +cv.imshow("red channel", red) ## green channel -cv.imshow("channel", green) +cv.namedWindow("green channel") +cv.imshow("green channel", green) ## blue channel -#cv.imshow("channel", blue) +cv.namedWindow("blue channel") +cv.imshow("blue channel", blue) + cv.waitKey(0) -cv.destroyWindow("channel") \ No newline at end of file +cv.destroyAllWindows() \ No newline at end of file