How to process the image that is present in UIAxes in app designer?

3 vues (au cours des 30 derniers jours)
Shilpi Gupta
Shilpi Gupta le 28 Nov 2020
Hello Sir
I am facing an error while designing a GUI in app designer.
How to process the image that is loaded in UIAxes.
Please Help.
  1 commentaire
Mario Malic
Mario Malic le 29 Nov 2020
Hi,
do the introductory examples in the App Designer, it'll help you alot.

Connectez-vous pour commenter.

Réponses (1)

Image Analyst
Image Analyst le 29 Nov 2020
You have the image in a variable first, like you used imread() to read it in:
rgbImage = imread(fileName);
imshow(rgbImage);
Now you can process rgbImage just like it's a matrix, because that's exactly what it is. The fact that you display it in an axes does not matter at all. For example let's say you wanted to make it gray scale and threshold it to find regions brighter than 100 and then find their area and mean brightness. You'd do
grayImage = rgb2gray(rgbImage);
binaryImage = grayImage > 100;
props = regionprops(binaryImage, grayImage, 'Area', 'MeanIntensity')
See? It has nothing at all to do with displaying anything, though you can display the binary image or any other image if you want to.
If you have an actual error, you forgot to tell us what it is. Please paste back here ALL the red text of the error message.

Catégories

En savoir plus sur Image Processing Toolbox dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by