Hi !
I'm searching for informations about how to draw a splash screen with Irrlicht while its driver is loading textures, vertices and other stuffs.
Thanks !
Splash screen
No! Not like the tech demo. The tech demo runs on time, which means that loading done or not, you will be put into the program.
What you want to do is draw your splash screen, render one frame ( just go through your render loop once ) and then call a function to load the resources. When the function is finished and all the resources are loaded, you can hide the splash screen and get on with your program.
What you want to do is draw your splash screen, render one frame ( just go through your render loop once ) and then call a function to load the resources. When the function is finished and all the resources are loaded, you can hide the splash screen and get on with your program.
Well, the easy answer would be threading. Making threads in C is quite easy, and there's quite a few libraries out there that would make it less of a daunting task to learn how they work. I used the wefts library to start my learning with threading (http://wefts.sourceforge.net/ Does it in a nice object oriented way).
Startup the thread that does your loading, go into the draw loop, and get the thread to set a flag or have some other form of detection to tell when you're done, then move on from your splash screen.
Startup the thread that does your loading, go into the draw loop, and get the thread to set a flag or have some other form of detection to tell when you're done, then move on from your splash screen.
Ideas ?
I've already tried to use threads, but it makes a fatal failure in Windows XP.
(if you could write a little bit of code, just to see how you would do that)
I've already tried to draw the "please wait" image before loading other datas, but it draw nothing : the image is loaded (it's wrote in the log), but nothing appears before entering in the main draw loop.
I would like to use a splash screen, before my app will run on a Pentium II 200 MHz , and the time that it loads all the images... is a bit long. (-> it will be a computer of my school, where I will run a little demo )[/u]
(if you could write a little bit of code, just to see how you would do that)
I've already tried to draw the "please wait" image before loading other datas, but it draw nothing : the image is loaded (it's wrote in the log), but nothing appears before entering in the main draw loop.
I would like to use a splash screen, before my app will run on a Pentium II 200 MHz , and the time that it loads all the images... is a bit long. (-> it will be a computer of my school, where I will run a little demo )[/u]
Time doesn't wait !
You might wanna take a look on this one:
http://www.castle.schimkat.dk/
.. which has a simple splashscreen.
Kind regards Sticky
http://www.castle.schimkat.dk/
.. which has a simple splashscreen.
Kind regards Sticky