Jump to content
Posted 19 May 2013 - 01:59 AM
Posted 19 May 2013 - 12:00 PM
Yes, this makes sense to me. When dealing with any pixel-perfect rendering, you should always represent your positions and sizes as integers. When you specify a 0.5f, the GPU will ultimately have to choose which pixel it gets mapped to (this is actually done based on your projection matrix). I'm not sure why it's different on NVIDIA vs ATI, but it's probably due to floating point math differences.
For pixel perfect rendering I would use an orthographic projection that maps directly to your screen resolution. Also make sure the viewport (glViewport() if you're using OpenGL) is also set to your screen resolution. Don't rely on the default viewport that is set for you when you bind the OpenGL context.
I've recently implemented font rendering using freetype and have had results almost exactly to what you have shown in your image.
Posted 19 May 2013 - 01:13 PM
Yes, im using an orthogonal matrix and a viewport according to the window size. About the difference on the cards ive realized that my ATI card runs on double precision while the NVIDIA is not.
So ill just stick to the integral values, now that i know it its ok