开发者

loading a JPG image into my GUI handle structure using the file open function in matlab

开发者 https://www.devze.com 2023-02-20 16:30 出处:网络
I doing a project in matlab for extracting characters from a jpg image. So far, i\'ve created a GUI using Guide and now i want to load an image from the disk memory into the GUI. I have created an ope

I doing a project in matlab for extracting characters from a jpg image. So far, i've created a GUI using Guide and now i want to load an image from the disk memory into the GUI. I have created an open drop down menu list, which has the load image menu item. I have used the uigetfile function which succ开发者_StackOverflowessfully opens the opendialog box with image files to load. The problem is how to transfer this image to my GUI workspace. If you have an idea of what i am trying to do, i will be glad to get your feedback. Thanks in advance


Well, assuming you've loaded the image into 'I', you can get it to appear using 'imshow(I)'. Just change the focus to an axes or panel handle first:

I=imread("imageName");
axes(handles.axes1);
imshow(I);
0

精彩评论

暂无评论...
验证码 换一张
取 消