Loading Screens

Anything related in any way to game development as a whole is welcome here. Tell us about your game, grace us with your project, show us your new YouTube video, etc.

Moderator: PC Supremacists

Post Reply
User avatar
thejahooli
Chaos Rift Junior
Chaos Rift Junior
Posts: 265
Joined: Fri Feb 20, 2009 7:45 pm
Location: London, England

Loading Screens

Post 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.
I'll make your software hardware.
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Re: Loading Screens

Post 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. ;)
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: Loading Screens

Post 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%
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
User avatar
Falco Girgis
Elysian Shadows Team
Elysian Shadows Team
Posts: 10294
Joined: Thu May 20, 2004 2:04 pm
Current Project: Elysian Shadows
Favorite Gaming Platforms: Dreamcast, SNES, NES
Programming Language of Choice: C/++
Location: Studio Vorbis, AL
Contact:

Re: Loading Screens

Post 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.
User avatar
avansc
Respected Programmer
Respected Programmer
Posts: 1708
Joined: Sun Nov 02, 2008 6:29 pm

Re: Loading Screens

Post 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.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
Post Reply