How do I extract the coordinates of a colored arrow on an otherwise black and white image?
4 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Coder Bee
am 2 Mai 2016
Kommentiert: Walter Roberson
am 10 Mai 2016
I have a black and white image (not grayscale) with a green arrow on it. I need to automatically get the coordinates of this line without using the impixel() function.

0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 2 Mai 2016
mask = YourImage(:,:,2) >= 200 & YourImage(:,:,1) <= 20; %Green presence but not much red, must be green arrow
[r, c] = find(mask);
11 Kommentare
Image Analyst
am 10 Mai 2016
Define coordinates. Coordinates of what? The center of the arrow? The tail? The head? Every single green pixel in the arrows? And why??? Why do you care about where some arrow from someone else's image is?
And do you want the coordinates with respect to the large composite image, or to the smaller sub-images? for example, the bottom arrow may be at line 600 with respect the the entire big image, but at line 140 with respect to the small subimage.
Walter Roberson
am 10 Mai 2016
Above the user indicated "Just need the coordinates of the line to calculate the mid-point of the arrow"
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Image Processing Toolbox finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!