In 2000 the PC port of Final Fantasy VIII was released. I was in the team that ported it and I clearly remember an outstanding bug for which I damned myself. It was about artifacts coming out of inconsistent subpixel bias across different graphics cards with Direct3D
The game was shipped with that bug.. a couple of weeks later a guy from nVidia told us: “Oh that’s easy you just have to offset all pixels by 0.5″. Easy he said, but in fact when asked about the issue earlier he said something about some other developers doing a a simple test rendering and reading back the buffer to estimate the subpixel bias settings when starting the game.. yuck !!!
Six years later, I’m still struggling with subpixel bias. This time with DSharingu and OpenGL.
To render texture for 1:1 ration pixel display in OpenGL it’s suggested to offset rendering by 0.375 pixels. This looks good if bilinear filtering is disabled, otherwise textures come out blurred.
Also, on my ATI 9700 AIW Pro, to render properly a frame rect with a GL_LINE_LOOP I have to offset pixels by 0.5. If I don’t there is going to be a pixel missing from a corner. This changes with the 9200 SE that I have another computer, which still misses a pixel but on a different corner !
Things get even funnier when trying to draw a small X with a couple of lines. Pixels tend to be missing on either ned of the line depending on more than one variable, obviously including hardware and drivers..
..it’s a rasterization mess !
I’ve wasted a lot of time on this and I’m not sure how to settle it.
My main problem is about text rendering. I build my own texture for text at run-time. It’s fast and looks nice because I subsample myself Windows rendered text so that I can be sure that I have antialiased text. However this doesn’t support Japanese text. To do that I’d have to use a lot more texture memory and implement a Shift-JIS rendering routine.. which is not too hard, but not too funny either.
well well
Posted by Davide Pasca in Programming
