Read the Image from the path and display the image in MATLAB GUI axes
이전 댓글 표시
Hello,
I am using MATLAB GUI guide to to develop the GUI for my project. I need to select the image from the folder (.png images) and display the selected image on axes in GUI. This action has to be done once the push button is clicked by the user.
Please let me know the function which helps me to meet my requirement.
Looking forward to hear from you at the earliest .
Thanks Pankaja
댓글 수: 2
Adam
2015년 7월 3일
Have you looked through the help? I'm fairly sure there are examples of this type of thing in there.
doc guide
doc imread
B.k Sumedha
2015년 7월 3일
How many images u want to display in the gui?
Are you selecting any one particular image from your path? Specify the requirements correctly.
채택된 답변
추가 답변 (1개)
If you are using the normal GUI builder, then you create automatically functions for the handles. Put under your buttonfunction the follow commands:
for opening file you can use this function:
for opening a folder you can use:
save the this path. I use for this setappdata.
then you need to recall your figure function and update it.
you can now can get the path by using getappdata
Few work example are given by Doug Hull, you should check these. They explained a lot for me.
Tip: Use a button with a commend Keyboard so you can use this button to debug
카테고리
도움말 센터 및 File Exchange에서 Display and Exploration에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!