This project is read-only.

2D without stretching

May 3, 2013 at 2:37 PM
How can I have a 2D setup without stretching.
I have an image texturing a quad but when I resize the window it stretches. I don't want stretching I want the viewport to get bigger. I want to maintain the aspect as well as being able to zoom and pan?

Any code snippets that does this?
May 5, 2013 at 4:42 PM
I'd search for standard OpenGL samples for this and then port them, but the short answer is that you'll have to scale the projection matrix to keep things at a constant size from the viewer's point of view. Also, you can try this: