imagen precessing

i am trying to open a picture but every time i tried it send and error "??? No appropriate method or public field mat for class image."
>> imagesc(image.mat) ??? No appropriate method or public field mat for class image.
>>

 Risposta accettata

Image Analyst
Image Analyst il 18 Mar 2012

1 voto

You need to first load your mat file with the load() function
if exist('image.mat', 'file')
% Load image from mat file.
storedStructure = load('image.mat');
% Get the image.
yourImage = storedStructure.yourImage;
% yourImage is whatever you called your image when you saved your mat file.
% Display it.
imagesc(yourImage);
% Get rid of the goofy default colormap
colormap(gray(256));
else
msgbox('File does not exist.');
end

Più risposte (0)

Categorie

Scopri di più su Convert Image Type in Centro assistenza e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by