Skip to content

Commit 02bcd83

Browse files
assignment day 2
1 parent f589619 commit 02bcd83

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

input2.png

2.61 KB
Loading

open.png

1.1 KB
Loading

xor_nor_ofImage.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import cv2
2+
img1=cv2.imread("input2.png")
3+
img2 = cv2.imread('open.png')
4+
dest_xor = cv2.bitwise_xor(img1, img2, mask=None)
5+
cv2.imshow('Bitwise XOR', dest_xor)
6+
dest_not1 = cv2.bitwise_not(img1, mask=None)
7+
dest_not2 = cv2.bitwise_not(img2, mask=None)
8+
9+
cv2.imshow('Bitwise NOT on image 1', dest_not1)
10+
cv2.imshow('Bitwise NOT on image 2', dest_not2)
11+
12+
if cv2.waitKey(0) & 0xff == 27:
13+
cv2.destroyAllWindows()

0 commit comments

Comments
 (0)