View Full Version : Coordinate .... system...

08-11-2001, 02:06 PM

I have a problem with setting up a 2D view. I crate a 800 x 600 window. And i set up the view the following way

glOrtho2d ( 0.0, width, 0.0, height );

its fine but when i put a point at (0, 0) that point is in the middle of the window. I was trying to get the point (0,0) to be at the bottom left of the window.

| |
| |
-> +--------------+

I tried changing the values around with glOrtho2D function but it didn't work. Does anyone have an idea how to do so....


08-11-2001, 02:07 PM
sorry the sqare i made came out a bit messed up http://www.opengl.org/discussion_boards/ubb/redface.gif

08-12-2001, 05:23 AM
Can think of two things.
1: You are doing transformations (which you are unaware of) in the modelview matrix, which translates the point to the middle.
2: You have called glViewport with the wrong aguments.