Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Get pixel coordinates of an image

Solved!
Go to solution

I cannot find a convenient function to get x,y coordinate of a thresholded image pixel (255).

Do I have to convert the image to array and then loop through all pixels to get the coordinates?

0 Kudos
Message 1 of 13
(5,668 Views)
Solution
Accepted by topic author tomsze
Check bounding rectangle of particle measurements : https://zone.ni.com/reference/en-XX/help/370281AC-01/nivisionconcepts/particle_measurements/
Thanks
uday
0 Kudos
Message 2 of 13
(5,637 Views)

Oh~ I mean I want to get all pixels(255) 's X,Y

0 Kudos
Message 3 of 13
(5,636 Views)
So you want all pixel location which has value 255?
- I don't understand why such a need, maybe if you explain full picture of what you are trying to do there could be some other means.
Thanks
uday
0 Kudos
Message 4 of 13
(5,626 Views)

Did you look at the result of IMAQ Particle Analysis VI?

Should be in the measurements from this VI.

 

Amit Shachaf
0 Kudos
Message 5 of 13
(5,614 Views)

I want to develop some new algorithms base on the coordinates first.

 

(Sorry I kept pressing wrong the solution buttonSmiley Embarassed)

0 Kudos
Message 6 of 13
(5,589 Views)

There is no particles 's all xy in IMAQ Particle Analysis.

0 Kudos
Message 7 of 13
(5,582 Views)
Imaq particle analysis report returns array of binary particle measurements which includes bounding rectangle of particle.
- give an example of what you are trying to do, so that it will be easier to suggest.
Thanks
uday
0 Kudos
Message 8 of 13
(5,575 Views)

For example,I want to compute the distances from the boundaries of binary particles.

0 Kudos
Message 9 of 13
(5,574 Views)
Particle analysis report gives the array of bounding box of particles. Once you have it you can get point to point distances between all particles.
Thanks
uday
0 Kudos
Message 10 of 13
(5,572 Views)