Tuesday, February 26, 2013

Finally generating LDP-1450 characters in GLES2

I finally broke down and wrote some GLES2 code (including a new vertex shader) to render LDP-1450 text overlay.  While this may sound like a trivial task, it was actually quite difficult coming up with an approach that would run fast on the Raspberry Pi.  Trying to just render to a frame buffer directly would've been far too slow so I needed to come up with a tile system.  I am still making speed improvements, but I am pretty confident that I am going in the right direction.

Here is how the original LDP-1450 text looks:


 Here is how my generated text looks using no filtering (ie nearest neighbor):


Here is how my generated text looks using filtering:


This isn't an exact comparison because the LDP-1450 text I captured is in "grey border" mode which I have not yet tackled, so you will kinda have to imagine that the grey border is not there.

Anyway, my conclusion is that the filtered mode is too smooth and the nearest neighbor mode is too rough.  I think maybe if I increase the size of the source texture by a factor of 2 (or maybe more if necessary) that I should be able to use filtering and still see some pixel edges like on the original LDP-1450.  Stay tuned...

No comments:

Post a Comment