View Full Version : How to change the default reference coordinate system
manrain
03-31-2003, 06:42 AM
The opengl default reference (eye) coordinate system is: the origin is at the center of the window,Z-axis points out of the screen, X-axis points to the right,and Y is up. All coordinate transformation is based on this coordinate system. Is there any way to redefine this reference frame. Thank.
What3v3r
03-31-2003, 07:49 AM
OpenGL coordinate system is right-handed by default and can't be changed. Direct3D lets you choose right-handed or left-handed coordinate system.
... unless you multiply your modelviewmatrix to convert between coordinate systems.
M=[ 1 0 0 0
0 1 0 0
0 0 -1 0
0 0 0 1 ]
will invert the z-axis so the camera is *effectively* looking down the +Z axix.
cheers,
John
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.