Flipping FTGL glyphs
After finally getting FTGL to work for me, I noticed that FTGLTextureFont:s render themselves upside down in my viewport. I could probably invert them by scaling my texture matrix by 1, -1, 1, but I'd rather not mess around with the GL state in that way, that much. I suppose that it would be possible to edit the FTGL itself, but before I embark on such a mission, I thought I'd ask if anyone has worked themselves around this in a more obvious way?
Which way up is your viewport? OpenGL traditionally puts the origin in the lower left; I'd assume that that's what FTGL assumes.
Why do you feel that changing the texture matrix is such a major operation? You can push and pop it just like any other matrix...
Why do you feel that changing the texture matrix is such a major operation? You can push and pop it just like any other matrix...
Are you rendering them in an ortho2d projection transform? I've never seen this happen in my code, but then, I've only used them in 2D overlays.
Considering your origin is top-left of the window, how did you properly flipped the font? I cannot do it by just scaling the y to -1 because its translating up above the screen by the font height. I have your old problem, can you give the solution?
Wow, almost ten years later..!
I remember that I just bit the bullet and flipped the viewport the right way up.
Had to correct a few things in game code, but it worked out all right.
Sorry, no better idea than this; but flipping the texture matrix might be easier if you have your font code encapsulated well.
I remember that I just bit the bullet and flipped the viewport the right way up.
Had to correct a few things in game code, but it worked out all right.
Sorry, no better idea than this; but flipping the texture matrix might be easier if you have your font code encapsulated well.
Ivan,
Just looking at the original date stamp of this post, was it in relation to El Ballo?
Just looking at the original date stamp of this post, was it in relation to El Ballo?