[Filename,Pathname]=uigetfile({'*.jpg';'*.png'}, 'File Selector');
name=strcat(Pathname,Filename);
a=imread(name);
imshow(a);
……..
this is to open file but i want to rgb2gray from this coding. how can i do? thank you for helping. im using menu editor gui and for rgb2gray that is another menu callback
Best Answer