Ask Your Question

Revision history [back]

Theory behind "center" of top-left pixel considered as (0, 0)

Hello,

I learnt from "resize bi-linear" implementation that the "center" of the (left top) pixel is considered as "origin" (0, 0). It appears that if "top left corner" were considered as origin then it would have actually simplified the equations. But as this is not done, there must be some theoretical reason behind choosing center as origin. I got one hint from below comment on http://answers.opencv.org/question/87923/sub-pixel-coordinate-origin/ by @StevenPuttemans: "origin is at the center of the top-left pixel, because else there would be an imbalance in coordinate systems with negative valued axes ..."

But unfortunately I'm unable to fully grasp it with above hint. Could Steven or anybody else provide some more theoretical details for clearing the concept...

Please let me know if you need any more info.

Thanks in adavance. -Pavan