I am trying to use guide and could use some help with functions in 2014a
Show older comments
I have a function "imgImport" which passes these output "im, hdr,old, datafile, hdrfile" but I can not grab this data in the next function. I noticed it is not propagating the data to the work space, and found that it is stored in the GUI. I have two buttons one to grab the image the second to crop the image; here is the function as I tried.
function pushbutton1_Callback(hObject, eventdata, handles)
%disp('imgImport')
[im, hdr,old, datafile, hdrfile]= imgImport;
% hObject handle to pushbutton1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% --- Executes on button press in pushbutton2.
function pushbutton2_Callback(hObject, eventdata, handles)
[imgVIS, imgSWIR, rect,img,rowend, rowstart, colend, colstart]= cropping(im, hdr);
% hObject handle to pushbutton2 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
How do I get one button to grab outputs from the other buttons data.
Accepted Answer
More Answers (0)
Categories
Find more on Read, Write, and Modify Image in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!