Skip to main content
gamedev.net
🔒 Locked

A question about loading

Started by llvllatrix Feb 15, 2003 at 2:20 PM 4 replies 250+ views
Original Post
llvllatrix
llvllatrix
For the next lotr contest, i had an idea about loading and unloading files that i needed for only one scene. I could break each scene into different threads (multi-threading) and have one thread play the scene and the other load the data for the next scene. Is this practicle?
vincoof
vincoof
Apart from the fact that you may not process GL calls in different threads, it''s fine. Though, unless the data to load is VERY big I would rather recommend a loading screen and wait in the beginning for a few seconds. Multithreading introduces lots of state sync hassle which I do not recommend when you can do without.
niyaw
niyaw
make sure your loading thread runs on low priority.
llvllatrix
llvllatrix
The problem is my demo, as it looks so far, will have to load lots of stuff and with a loading screen it means eatting up a lot of memory. So, i was considering loading it a bit at a time between scenes, but that would mess up the link to the music. So i think i''ll try multithreading. Hopefully you guys wont mind large demos...do you?
vincoof
vincoof
There''s also another problem with dynamic loading : you''re never sure that the data is ready when you need it. It loading takes too much time, what will you do ? please wait while loading ? dismiss the scene ? see half or the scene ? crash ?!
when data is loaded at start, you know that data is always ready at the second the loading screen ended.

quote:

Hopefully you guys wont mind large demos...do you?

I don''t mind but maybe NeHe does. You should ask him since he''s the one who rules the rules.
rodzilla
rodzilla
Maybe Jeff should put a 512 Kb limit for that contest so you don''t have problems loading huge files ;*)

That would make the data file copyright problem irrelevant as well...
SaM3d!, a cross-platform API for 3d based on SDL and OpenGL.The trouble is that things never get better, they just stay the same, only more so. -- (Terry Pratchett, Eric)

Topic Locked

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

Sign in to reply to this topic.