-
Notifications
You must be signed in to change notification settings - Fork 0
Coordinate frames
Mitchell Epp edited this page Feb 23, 2020
·
3 revisions
Preliminary definition of the coordinate frames. This will likely change.
General idea
- Every frame should be right-handed. This ensures rotations between frames are actually rotations and generally simplifies things to some extent.
- For all frames, x is right/horizontal, y is up/vertical, and z is backward/outward (note - an older version used the ROS convention for model/world space, so there may still be traces of this throughout the code).
- Aside from this, frames generally should resemble OpenGL frames.
Specific frames
- model space: the frame in which models are defined. (0,0,0) is effectively the center of rotation of the model.
- world space: frame common to all models (if models store a pose transform, it transforms them into this frame).
- view space: points are transformed from world space to view space by the camera pose transform.
- clip space: The perspective transforms brings points in view space to this space. OpenGL uses this for clipping but I'm not doing that yet.
- ndc space: NDC (normalized device coordinates) space, the first 2D space, results from transforming the homogenous clip-space coordinate to 3D (by performing the perspective divide) and dropping the z-coordinate.
- window space: the coordinates of individual pixels. This is ndc space scaled and translated to fit the current window.