View Full Version : printing text
02-07-2000, 08:48 AM
I have been unable to get any of the standard methods of rendering text to work when rendering to a memory context (DIB). I have tried wgl, texmapping the glyphs, and now GDI, all to limited success. I would refer to have the wgl methods functioning, as that is how all the other text is done in the display. Does anyone have advice for rendering text to a DIB? Have I set up something wrong (pfd?, header?). All other openGL prints fine...just text never shows up.
Any help greatly appreciated.
02-08-2000, 01:34 AM
Hang on - are you saying that normal texture mapped polys work fine, but magically break when the texture happens to contain glyphs?!
One thing that catches me out embarrassingly often when using using texture fonts is that the normal text Y coordinate mapping mode - with 0 at the top and coords increasing down the screen - is the _reverse_ of the standard OpenGL coord space. Are your text quads maybe getting backface culled?
02-08-2000, 05:57 AM
actually, no. They worked fine with the glyphs on screen, but the lack of alpha blending support for DIBs left me with a solid quad on the printout (blitted from the memory context).
I have fixed it, in me infantile knowledge of DCs and such I did not notice that the base class never associated a font with the DC, so when I made a compatible DC it had no font, and therefore no text.
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.