How to converting RGBa (m x n x 4) .tif image to RGB (m x n x 3) .tif
48 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Zander
el 23 de Mzo. de 2014
Comentada: Zander
el 23 de Mzo. de 2014
After help on my previous question, I have found that some images I want to crop (using imcrop) have been converted to RGBa due to some previous operations in paint.net (I flattened the images but still can't remove the Alpha). I thought they might be cmyk and tried a conversion I found but this gave a weird reversed image so thus I am pretty sure I have RGBa.
Does anyone have any code to convert my images within my cropping function? I have spent hours searching but to no avail.
Many thanks
0 comentarios
Respuesta aceptada
Image Analyst
el 23 de Mzo. de 2014
Why can't you just do
% Extract only channels 1, 2, & 3.
rgbImage = rgbImage(:,:,1:3);
??? What do you mean you "Flattened" the image? Can you attach your image so we can try stuff?
2 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!