[SOLVED] Bit plane merging
Posted: 2016-11-29T02:18:40-07:00
Hello,
I have found a way to do some steganography with imagemagick and it's capacity to extract bit planes, but now I'm stuck for merging the different bit planes.
I have two images A and B (same size):
A is the mask et B the secret i want to hide.
On A I do :
to keep the 4 most significant bits.
On B I do :
to keep the 4 most significant bits and shift them to the 4 less significant ones.
The question is : How do I merge A and B to make my final image C ?
Code to recover the secret :
P.S. Sorry for my English (french).
I have found a way to do some steganography with imagemagick and it's capacity to extract bit planes, but now I'm stuck for merging the different bit planes.
I have two images A and B (same size):
A is the mask et B the secret i want to hide.
On A I do :
Code: Select all
convert A -fx '(int(u*255)&240)/255' A
On B I do :
Code: Select all
convert B -fx '(int(u*255)&240)/(255*16)' B
The question is : How do I merge A and B to make my final image C ?
Code to recover the secret :
Code: Select all
convert C -fx '(int(u*255)&15)*(16/255)' D