Jesse Aldridge
08-21-2005, 05:18 PM
I'm moving from an SDL based to an OpenGL based system for rendering. With SDL, I had a system based on pixel dimensions. In order to make this transition as easy as possible, I'd like to get OpenGL set up in the same way, so that when sprites are drawn at their normal size (dimensions on screen = dimensions on file; unscaled) the left and right side of the view are 800 units apart and the top and bottom are 600 units apart.
Currently, it seems like sprites are drawn at there normal size when z = -15. This makes the left side of the screen -9.2 (or something like that). These numbers are rather unintuitive for me to work with, but I can't figure out how to change them. glOrtho seems like it may do what I want, but I think I may want to take advantage of some 3d functionality in the future, so I'd like to work with glPerspective if I can.
Currently, it seems like sprites are drawn at there normal size when z = -15. This makes the left side of the screen -9.2 (or something like that). These numbers are rather unintuitive for me to work with, but I can't figure out how to change them. glOrtho seems like it may do what I want, but I think I may want to take advantage of some 3d functionality in the future, so I'd like to work with glPerspective if I can.