Problem with xor operation
Posted
by gavishna
on Stack Overflow
See other posts from Stack Overflow
or by gavishna
Published on 2010-06-13T15:50:39Z
Indexed on
2010/06/13
15:52 UTC
Read the original article
Hit count: 197
Kindly tell me why the original image is not coming with this code. The resulting image receive is yellowish in color,instead of being similar to the image Img_new
Img=imread(‘lena_color.tif’); Img_new=rgb2gray(img); Send=zeroes(size(Img_new); Receive= zeroes(size(Img_new); Mask= rand(size(Img_new); for i=1 :256 for j=1:256 Send(i,j)=xor( Img_new(i,j),mask(i,j)); End End
image(send); imshow(send);
for i=1 :256 for j=1:256 receive(i,j)=xor( send(i,j),mask(i,j)); End End
image(receive); imshow(receive);
plz help
© Stack Overflow or respective owner