Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Pixel scale is inverted in the Y direction but not in the X direction

I am grabbing an image from a camera (or reading an image file) and processing the image to find the centroid.  I am then converting the image to a grey scale and plotting the image on an intensity graph to convert intensitys to colors.  The images are correct and upright.  However, when I read the pixel positions the pixel position increases with an increase in x but decreases with an increase in Y (ref at lower left of image) and when I plot the image on an intensity graph Y is inverted and X is normal.  How cam I correct this?
0 Kudos
Message 1 of 3
(2,928 Views)

Hi,

you may solve this problem by evaluation of Y position using this formula:

 

Ynew=Ymax-Yi  (i is the cuurent pixel value). 

 

Does it help?

Waleed El-Badry MSc.,MCPD, ISTQB Certified Tester
Assistant Lecturer
Mechatronics Department
Faculty of Engineering
Misr University for Science & Technology



View Waleed El-Badry's profile on LinkedIn

0 Kudos
Message 2 of 3
(2,915 Views)

Here's an easier method.  Invert the Y axis of the intensity graph.  Right now it is zero to N.  Double click on N and type a zero.  This will flip the axis.

 

Bruce

Bruce Ammons
Ammons Engineering
Message 3 of 3
(2,910 Views)