Page 1 of 1
Loading Screens
Posted: Sat Oct 24, 2009 7:29 pm
by thejahooli
How are loading screens done in games?
How do they update the loading screen while also loading?
The first things that I could think of is having it in between different objects being loaded but this would mean that they couldn't update it when loading a particularly large file.
Re: Loading Screens
Posted: Sat Oct 24, 2009 7:41 pm
by Falco Girgis
thejahooli wrote:How are loading screens done in games?
How do they update the loading screen while also loading?
The first things that I could think of is having it in between different objects being loaded but this would mean that they couldn't update it when loading a particularly large file.
The load screen that I built for Viva La Samba (for streaming music from the PC to the Dreamcast) split the file into chunks. I transferred as much as possible per frame to maintain 60fps, updated, and rerendered the scene.
Another approach would also be to use multiple threads in your application. One thread is transferring, the other is updating/redrawing your load bar... but that's not very fun.
Re: Loading Screens
Posted: Sat Oct 24, 2009 10:14 pm
by avansc
well lets say you have X amount of things you are going to load.
you can push all that onto a queue.
then loop through the queue and after every iteration signal the loading bar to display N/X*100%
Re: Loading Screens
Posted: Sat Oct 24, 2009 10:44 pm
by Falco Girgis
avansc wrote:well lets say you have X amount of things you are going to load.
you can push all that onto a queue.
then loop through the queue and after every iteration signal the loading bar to display N/X*100%
And how are you going to be rendering the scene? How is this not going to be choppy? If you have a large file (or even one file), the load bar is going to be jumping from 0 to 100% without ever having an intermediate step.
You aren't addressing his question. He asked how you can load something while updating/rendering a scene.
Re: Loading Screens
Posted: Sat Oct 24, 2009 11:37 pm
by avansc
GyroVorbis wrote:avansc wrote:well lets say you have X amount of things you are going to load.
you can push all that onto a queue.
then loop through the queue and after every iteration signal the loading bar to display N/X*100%
And how are you going to be rendering the scene? How is this not going to be choppy? If you have a large file (or even one file), the load bar is going to be jumping from 0 to 100% without ever having an intermediate step.
You aren't addressing his question. He asked how you can load something while updating/rendering a scene.
actually... he asked "How do they update the loading screen while also loading?"
not a actual game scene.
also. if you are only going to load 10 things. its probably going to do it so fast that you wont need a loading screen.
and yes its not a perfect solution. but unless you can store all your data as binary, and load bit for bit.. you are gonna have jumps.
and when you get to have larger levels with 1000's of objects that you preload. a large file might jump from 23% to 33% or something like that..
if you look at almost any game that has a loading screen. you will see that its jagged and there are jumps. infact i think of late games have just used a loading in progress indicator.