Skip to main content
gamedev.net
🔒 Locked

title screen

Started by qx452 2 replies 1.1k views
Original Post
qx452
qx452
What is the best way to draw the 640x480 titlescreen background? I tried glDrawPixels() and it was super slow (2 FPS). So then I tried GDI BitBlt() and although everyone says its slow, it seemed to be fast enough for drawing the 640x480 titlescreen background. However when I tried to use it with OpenGL at the same time (draw the titlescreen background with BitBlt() and then use glBegin()/glEnd() to draw the GUI on top) I ran into problems. At first my system locking up. I tried moving it to different places and now it flickers (it appears to draw the background with BitBlt() then clear the screen and draw the GL stuff then clear then BitBlt(). I checked and there was no glClear() or anything causing that to happen between the two drawings. Then I commented out the SwapBuffers() and the GDI works but the GL doesnt show up. So... It seems my options are to use multiple textures. Or get GDI working. Multiple textures would waste video memory cause most of the time the title screen isnt drawn. Is multiple textures for the 640x480 title screen a good idea or should I use GDI? If GDI, any suggestions on how to get it working along with GL? Advanced Thanks
Hazel
Hazel
I''ve also had such a problem when I was writing my first ''big'' OpenGL program. But the way I solved it may not satisfy you.

I simply loaded the title picture in any graphics program, resized it to 512x512 and then displayed with GL_ORTHO on a normal GL_QUAD. Of course, the picture gets very blurred, but it didn''t need to be sharp in the program I used it.

Hope it''s of any help,
Greetings,
Hazel
Null and Void
Null and Void
Just get use a big texture and scale it down. Or, if you want to support some older video cards that can't handle larger textures (Voodoo cards, notably), use multiple textures. You can possible have a ruitine to split up the texture at runtime for the cards that can't handle whatever size you want to use.

[EDIT: Fixing a typo. Someone posted before me though, heh ]

[Resist Windows XP's Invasive Production Activation Technology!]

Edited by - Null and Void on December 23, 2001 3:57:26 PM
zedzeek
zedzeek
as null + void saiz though i would use a 1024x512 sized texture + only use 640x480 of it

http://uk.geocities.com/sloppyturds/gotterdammerung.html

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.