Archived

This topic is now archived and is closed to further replies.

fading scenes and logo starting

This topic is 5744 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi i am a beginner openGL programmer.I am using using nehe''s basecode and i have the following questions: 1) I want to fade one scene to other...Not just a texture to other..I do it with blending? can you help? 2) i load some textures in the beginning of my game and the application takes some time to load.Is there a way to present a .bmp logo to the screen WHILE the scene loads, and thene dissapear the logo and start thw windowed app? The thing is that the .bmp must appear outside of a window.( just like the way Unreal Tournament starts) Thanks a lot for your time!

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
1.) no real idea,
2.) create a window withe the fullscreen flags(but don''t change the resolution) , load a picture and draw it an the window.

Share this post


Link to post
Share on other sites

Maybe this link contains stuff which might be of interest to you

http://romka.demonews.com/opengl/demos/other_eng.htm

it has menu systems and a flashing front menu sample code on it

Regards
- Pete

Share this post


Link to post
Share on other sites
Hi.I dont want a menu to use from inside the game ( i know to do that)I want a bmp screen to appear OUTSIDE the game window( Have you played Unreal Tournament?)
About the fading scenes i believe i should use the glClearScreen but i dont know hot to change it dynamically.I could use the blending way but i am not sure how exactly i should do that
Thanks a lot!

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
quote:
Original post by ironhell3
Hi.I dont want a menu to use from inside the game ( i know to do that)I want a bmp screen to appear OUTSIDE the game window( Have you played Unreal Tournament?)



It''s not outside the window. It''s inside a different window.

Share this post


Link to post
Share on other sites
What about, rendering all the stuff in perspective, then switch to glOrtho, and draw a Black quad on the screen (the size of the screen so it covers all the screen), then adjust the alpha to the quad slowly so it fades out, when it becomes completelly transparent you just stop rendering the quad, simple.

Share this post


Link to post
Share on other sites
I''ve done a number of things to cause screenfade. The best technique for me is, when all 3d drawing is done, and I am in my 2d ortho mode (for text/gui..., all my apps have a 3d pass, then a 2d pass in every frame), is to render/alphablend a fullscreen black/etc quad and vary the alpha over time.

In my current framework, I can setup 4 types of dimming on the fly w/ 1 command:
1. no fade to full fade, shape "/" used mostly for app end fade
2. full fade to no fade, shape" \" used mostly for app start fade
3. no fade to full fade to no fade, shape "A" used mostly for interscene fades
4. full fade to no fade to full fade, shape "V" never used it but could for a peek at some image

The dim can be in any color and to any ultimate opacity value (though usually 1), over any amount of time:

screen.set_dim(type,seconds, r,g,b,a); which just sets up some vars.

My display func calls screen.do_dim() when in 2d ortho, which checks the vars and does the appropriate thing if needed.

zin

zintel.com - 3d graphics & more or less

Share this post


Link to post
Share on other sites
You can make a splash screen like this:

Create a splash screen window with a picture. You can use a dialog here.
Call CreateDialog or CreateWindow. If the window doesn''t have WS_VISIBLE, also call ShowWindow and UpdateWindow.
Execute creation code. This includes creating your main window and initing graphics.
Call DestroyWindow on your splash screen.
Call ShowWindow on your main window.
After this, go to the game loop.

I implemented a splash screen like this. It only has "loading please wait" string, though, as I suck at making graphics.

IMO, UT doesn''t show splash screen long enough. It does still more init work after the window is created, and even more after it switches video mode.

Share this post


Link to post
Share on other sites