Knowledge Garden

Search

Search IconIcon to open search

{{title}}

Last updated Oct 27, 2022 Edit Source

# References:

  1. Andy Johnson’s CS 488 Course Notes, Lecture 5
  2. Foley, Van Dam, Feiner, and Hughes, “Computer Graphics - Principles and Practice”, Chapter ??
  3. Woo et. al., OpenGL Programming Guide

# Coordinate System “Handedness”

In a 2-D coordinate system the X axis generally points from left to right, and the Y axis generally points from bottom to top. ( Although some windowing systems will have their Y coordinates going from top to bottom. )

When we add the third coordinate, Z, we have a choice as to whether the Z-axis points into the screen or out of the screen:

Right Hand Coordinate System (RHS)
Z is coming out of the page

Counterclockwise rotations are positive
if we rotate about the X axis : the rotation Y->Z is positive
if we rotate about the Y axis : the rotation Z->X is positive
if we rotate about the Z axis : the rotation X->Y is positive

Left Hand Coordinate System (LHS)
Z is going into the page

Clockwise rotations are positive
if we rotate about the X axis : the rotation Y->Z is positive
if we rotate about the Y axis : the rotation Z->X is positive
if we rotate about the Z axis : the rotation X->Y is positive

so basically its the same thing …

The important thing to note is what coordinate system is being used by the package you are working with, both for the creation of models and the displaying of them. Also note that if the two packages use different coordinate systems, then the model(s) may need to be inverted in some fashion when they are loaded in for viewing.

OpenGL generally uses a right-hand coordinate system.

# Multiple Coordinate Systems in a Graphics Program

In a typical graphics program, we may need to deal with a number of different coordinate systems, and a good part of the work ( and the cause of many headaches ) is the conversion of coordinates from one system to another. We’ll learn about the conversion process a little later, but in the meantime, here is a list of some of the coordinate systems you may encounter:

https://www.cs.uic.edu/~jbell/CourseNotes/ComputerGraphics/Coordinates.html