PDA

View Full Version : memory bitmaps



Shag
07-28-2005, 02:32 PM
dumb question...

i want to create a bitmap in memory, write some text on it, then upload it to opengl.

can anyone tell me how to do this?

many thanks!

mark

PS - i'm using windows

Relic
07-29-2005, 01:38 AM
http://msdn.microsoft.com/
Search for
- CreateCompatibleDC
- CreateDIBitmap
- SelectObject
- FillRect
- TextOut
- GetDIBits

Create a memory DC, a device independent bitmap, fill it with your background color, select a font, write the text with text out, get the bits, use glTexImage2D.

Better search the internet for someone who did all that already.