The XOR is a point operation (i.e. it performs the operation in a pixel by pixel manner). When two pixels are equal the XOR returns 0, otherwise it returns 1. In that sense, the XOR highlights the differences between two images.
.If you convert each element to its byte form and apply what Altahir explains you will get :
1 In case it is applied on same image ie A=B xo rB .. a blank A= 0 value
2 If you apply it on a sequence of images B1, B2 you will get the changes( dissimilarities.. perhaps you can use this to determine change of scene or track movements in videos.
@Aparna Sathya Murthy, XOR operation is not secure while applying in image encryption. So just searching a complex (extended) form of XOR operation which can be a combination of multiple XOR operations.
Yes I confirm the last answer your question is in the field of cryptography/cryptanalysis. You have a great amount of choice. The most important think, is that any operations you may combine (in non RSA kind of cipher, like AES, DES etc or simply linear coding scheme) must be maps to maps, like rotation and XOR.
In term of mathematics, you are obliged to work in a really difficult domain which is the ring of polynomial of Gallois Field of order 2 (Z/2Z) quotiented by an other polynomial (I guess irreductible in the primary ring). You get also a field If I am correct, and in this field XOR is simply addtion.
I not a real specialist in this area but I have been confronted with a problem recently in this fild.
And I have certainly made some mistakes in the explications, so I leave the real specialists in the domain to correct my answer.
If it is just a problem of computer implemention there are great library for that openSSL has various cypher. And there is also the openGPG library, and others .... (of course for cryptography, for cryptanalysis it is very difficult to find something interesting, you certainly understand why ;-)
XOR operation is not secure if the same key is being used for encryption of different images as if A and B are images and K being the key then E1=XOR(A,K) and E2=XOR(B,K) where E1, E2 being encrypted images which are readily available for attacker then XOR(E1,E2)=XOR(A,B) which means attacker will have some information about original images.
one solution is to use different keys for different objects while another one is to use several rounds of xor operation with different keys say (XOR(XOR(A, K1), K2)) where K1, K2 belongs to K. AES and DES use no. of rounds to encrypt the data.
hi ... you not need to extend the xor operation, you need to method to encrypt an image. the xor is tool to easy encrypt and decrypt. my idea is develop technique to encryption an image with has all security measures ...