ユーザーが2つの画像をロードするときに、これらの2つの画像に適用する算術演算を選択するGUI環境を実装したいと考えています。私はこの場所で立ち往生しています。適用する「ケース」値で使用するコードを教えてください。
function pushbutton3_Callback(hObject, eventdata, handles)
% hObject handle to pushbutton3 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
contents = get(handles.popupmenu1,'String');
popupmenu4value = contents{get(handles.popupmenu1,'Value')};
% Hints: contents = cellstr(get(hObject,'String')) returns popupmenu1contents as cell array
% contents{get(hObject,'Value')} returns selected item from
popupmenu1
switch popupmenu4value
case 'Add'
%function of A
set(handles.figure1,'CurrentAxes',handles.axes3);
imshow(img2,[]);
case 'B'
%function of B
end