BMP256 not supported

4 Ansichten (letzte 30 Tage)
Philip Chin
Philip Chin am 7 Jul. 2025
Kommentiert: Altaïr am 10 Jul. 2025
I get this "Warning: Image format 'bmp256' will not be supported in a future release. " on my code when saving graphics to bmp format.
Is there a work around possible?
  1 Kommentar
Altaïr
Altaïr am 10 Jul. 2025
Here's what I did in MATLAB R2025a to export the current figure in bmp format. However, I did not face any warnings.
fig = getframe(gcf); % Capture the current figure as an image
rgbImage = fig.cdata; % Extract the RGB image data
% Convert to indexed image with 256 colors
[indexedImage, cmap] = rgb2ind(rgbImage, 256);
% Save as BMP file
imwrite(indexedImage, cmap, 'myfigure.bmp', 'bmp');
If you still face the warning please attach a simplified code that can be executed to reproduce the warning.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Printing and Saving finden Sie in Help Center und File Exchange

Produkte


Version

R2025a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by