next up previous contents index
Next: Manipulating the Camera Up: The Camera Previous: The Body   Contents   Index

The Lens

The lens is a mapping from the world to the screen. ePiX comes with three lenses: shadow (the default), fisheye, and bubble. Each lens simulates the appearance of world objects as seen by an observer at the viewpoint. The shadow lens is point projection from the viewpoint to the screen plane. Each of the other lenses performs radial projection to a sphere centered at the viewpoint, then maps the sphere to the screen plane; the fisheye lens does orthogonal projection (so the entire image lies inside a disk, and positions behind the camera are inverted) while the bubble lens does stereographic projection from the point directly behind the viewpoint.

Other lenses may be defined; the file camera.cc may be consulted as a template. Syntactically, a lens is a pair-valued function of a single P argument. To ensure expected behavior a lens should respect the meaning of the camera body.



Andrew D. Hwang 2004-09-04