PDA

View Full Version : 2D OpenGL Question



Doctor Slush
08-16-2002, 07:29 AM
I'm relatively new to OpenGL, and have no problems making 3D demos.

My problem is drawing 2D graphics using actual window coordinates. I know about the glBitmap function and the others that allow you to copy, pixel for pixel, a bitmap. What I want to do is be able to draw a specific bitmap at a specific coordinate (given in pixels) at a given rotation and scale. What functions should I be looking at to do this?

kevinhoque
08-16-2002, 08:28 AM
Don't think that the pixel routines (glPixelx, glRasterx, glDrawPixels, etc) are affected by glRotatex, glTranlatex. [Pretty sure of this.] I would use textured polygons to achieve the required effect. Incidently, you can scale an image using glPixelZoom. but I think that it would be wiser to do the whole lot using textured polys. http://www.opengl.org/discussion_boards/ubb/smile.gif

Kevin

Robbo
08-16-2002, 08:41 AM
I feel sure I've already posted to this one!?? (maybe a cross post???).

Anyway, use orthographic projection.