Advertisement

weird RasterPos

Started by July 17, 2003 11:34 AM
9 comments, last by desertcube 21 years, 7 months ago
As Bob precised, it's normal that Y looks reversed. You can query glGet with GL_VIEWPORT if you want to be sure which viewport dimension is currently in use.

Clip coordinates are part of the coordinate transformation.
when you call glVertex or glRasterPos, you specify coordinates in object-space. Then some transformations are applied, for instance the modelview and projection matrices, and finally end up in window coordinates for filling the framebuffer. The OpenGL specification completely describes the vertex transformation as is :
Object coordinates ---[modelview matrix]---> Eye coordinates ---[projection matrix]---> Clip coordinates ---[perspective division]---> normalized device coordinates ---[viewport]---> window coordinates

quote:

I need glGet so I can increase the y co-ordinate when i do a new line. At the moment I am storing this value, but it would be nice to be able to just reset x to 0 and increment y by the line's height.


If you want to go to a new line for objects positioned by glRasterPos, you can call glBitmap with a NULL bitmap and with your preferred x and y offsets.

[edited by - vincoof on July 22, 2003 3:47:08 PM]

This topic is closed to new replies.

Advertisement