My program needs to compute the angle of a pixel from a computer vision camera that has 120 degrees horizontal field of view, and resolution of 640 pixels wide and 480 pixels high.
Program receives an X,Y array of pixels for each image frame from camera. For left-most pixel, X would be 0 and angle would be -60 degrees. For right-most pixel, X would be 639 and angle 60 degrees. For center pixel, X would be 320 and angle 0.
How is angle computed when (X is > 0 and < 320) and (>320 and <640)?