when i am pressing the push button " show all the techniques" the image is showing all the pictures, but when I select any other push button after that it is not working. Can you please help me ?
1 次查看(过去 30 天)
显示 更早的评论
% --- Executes on button press in pushbutton1. function pushbutton1_Callback(hObject, eventdata, handles)
axes(handles.axes1);
a=imread('butterfly.jpg');
b=rgb2gray(a);
e=edge(b,'sobel');
f=edge(b,'canny');
g=edge(b,'prewitt');
h=edge(b,'roberts');
i=edge(b,'log');
j=edge(b,'zerocross',[]);
subplot(3,2,1);imshow(e);title('SOBEL EDGE DETECTOR');
subplot(3,2,2);imshow(f);title('CANNY EDGE DETECTOR');
subplot(3,2,3);imshow(g);title('PREWITT EDGE DETECTOR');
subplot(3,2,4);imshow(h);title('ROBERTS EDGE DETECTOR');
subplot(3,2,5);imshow(i);title('LAPLACIAN OF GAUSSIAN METHOD');
subplot(3,2,6);imshow(j);title('ZERO CROSS METHOD');
% --- Executes on button press in pushbutton2. function pushbutton2_Callback(hObject, eventdata, handles)
axes(handles.axes1);
a=imread('butterfly.jpg');
imshow(a);
% --- Executes on button press in pushbutton3.
function pushbutton3_Callback(hObject, eventdata, handles)
axes(handles.axes1);
a=imread('butterfly.jpg');
b=rgb2gray(a); imshow(b);
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Interactive Control and Callbacks 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!