Represent a point by the column of homogeneous coordinates . The actions of the four matrices are:
MatrixGeometric action and parameters
A proper rotation about the -axis: . The angle is in radians, with the usual right-hand sense.
A translation by : .
Uniform scaling by : . Positive gives a uniform dilation; collapses the object to the origin; negative additionally reverses its direction through the origin.
Perspective projection from the origin onto the plane , where is the focal length in the chosen coordinate units.
The last operation produces . It requires a perspective divide: divide the first three components by the last. For ,
This is why the last component of homogeneous coordinates cannot simply be discarded. Points with have no finite projected position, and a visible scene normally uses under this forward-axis convention. The first three transformations leave the last component equal to one and need no nontrivial divide. The displayed retains no depth variation after division; it describes projection onto the image plane, rather than a complete depth-buffer mapping.
Interpret the given focal point as the centre of perspective projection, . First translate it to the origin with . The direction from to the world origin is then , of length 10. Choose the rotation matrix so that this direction becomes :
Indeed, the transformed component is , and the transformed component is . Thus the required mapping, followed by the perspective divide, is
For a world point , its camera coordinates and projected device coordinates are
The world origin projects to and lies at camera depth 10. A point five units along the unit viewing direction from has camera coordinates , so it lies on the central image plane as expected. Here device coordinates are image-plane coordinates centred on the optical axis; an actual pixel viewport would require its own specified scale and offset.
Only rotations about the -axis are available. Consequently the camera's horizontal axis stays parallel to the world -axis; the viewing direction lies in the world plane. The available orientation has pitch but no independent yaw or roll. Translations move the camera and the projected origin but cannot supply the missing orientation degrees of freedom.

Articles by others on the same topic (0)

There are currently no matching articles.