image in image using hiding
Mostrar comentarios más antiguos
what we can do?
1 comentario
There are some examples on the File Exchange
And lots of threads on LSB encoding on the forum
If you're trying to cram a large 3-channel image into a single bitplane of a smaller 1-channel image, you're going to have to decide how much data you want to lose and how you want to lose it. Even after resizing the host image, you're still trying to fit 4.7E6 bits of data into 1.2E6 bits. You can reduce the size of the payload by reducing its geometry, or bits per sample. You can also convert it to an indexed image, but the question asks about embedding RGB content, so I don't know that's acceptable.
There's also the option to use more than the least-significant bit plane, but that would rapidly become visually noticeable. Certainly, occupying the 5 least-significant bit planes with payload would be more than obvious.
It's also worth noting that you're not maintaining the aspect ratio of the host image when you resize it, which is kind of a dead giveaway that the image has been modified. Use NaN in the geometry specification to specify a slack dimension.
Respuesta aceptada
Más respuestas (1)
Image Analyst
el 22 de En. de 2022
0 votos
I'm attaching an example of hiding a gray scale image in a gray scale image. It should be no problem for you to adapt it to use one or both as RGB images.
5 comentarios
elma ozge
el 23 de En. de 2022
Image Analyst
el 23 de En. de 2022
My code does that. Just take it one step at a time. Split your images into 3 parts
[rCover, gCover, bCover] = imsplit(rgbCover);
[rHidden, gHidden, bHidden] = imsplit(rgbWatermark);
Now use my code 3 times.
Hide rHidden in rCover, hide gHidden in gCover, and hide bHidden in bCover. Then recombine the separate color channels into one RGB image using cat():
rStego = cat(3, rCover, gCover, bCover);
I'm pretty sure it's not beyond your capabilities!
elma ozge
el 23 de En. de 2022
yanqi liu
el 24 de En. de 2022
yes,sir,may be use
if numberOfColorChannels > 1
% If it's color, extract the red channel.
hiddenImage = [hiddenImage(:,:,1) hiddenImage(:,:,2) hiddenImage(:,:,3)];
end
to make the matrix into 2 dimension
Image Analyst
el 24 de En. de 2022
Yes, you can do what Yanqi said. Just make sure you have enough pixels to do the hiding. This means that you need to have at least 8 times the number of pixels in the red, green, and blue channels all summed together. So if your RGB image is 256x256x3 = 196,608 pixels, then you'll need to have a gray scale image of at least 196,608*8 = 1,572,864 gray scale pixels.
Categorías
Más información sobre Image Arithmetic en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



