Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / let the movie play!

Author
Message
unitech
17
Years of Service
User Offline
Joined: 27th Jun 2007
Location:
Posted: 29th Sep 2007 21:03 Edited at: 30th Sep 2007 18:03
Ok something I was trying to get working and passed on, I'm now starting to think about...


I was trying to find a way to play a movie during the loading of all the models and such. But I could not to find a way to get the dbSync command to run .. I experimented with a flash over lay but for some reason any window launched from DB waits on dbSync as well. I'm not even going to try to understand that one.

So my question is how would one go about running the dbSync command automatically based on time or frame rate? Is this even possible with out a multi treading?
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 1st Oct 2007 14:56
Make a launcher - Load two processes - Not even same EXE - Will work if not full screen - might not work full screen - cuz when you switch all the objects/textures/ etc get dumped from ram.

A Launcher could load and fire off a movie - while the game is loading - you should be able to minimize the window, and you could use a drop file or some other cheap "process to process" communication - to possible shut off the moive as soon as the DarkGDK game portion is done loading. It may play choppy though.

unitech
17
Years of Service
User Offline
Joined: 27th Jun 2007
Location:
Posted: 1st Oct 2007 18:55
This is what i tried for the flash player, but it didnt work. What do you mean by launcher. a c++ launcher ? or is it specific to GDK?
RPDan
17
Years of Service
User Offline
Joined: 29th Apr 2007
Location:
Posted: 1st Oct 2007 19:54
If you are using the C++ version then it would be posibble to use multithreading.
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 2nd Oct 2007 00:56
Unitech - RPDan is probably correct. What I propose is a simpler way (possibly) to effectively do the same thing as RPDan's suggestion.

In short - both of our theories are the same - implementation is much different - that's all.

Basically you are saying you want a movie to play while DarkGDK loads your media right? (Iron Infantry is looking like its going to have a long load time also!) Well this is a great idea but take note: Movie players GENERALLY require a decent amount of CPU (Not MAJOR but...) cycles as they play. Loading Media (in my experience) is definately a CPU hog - at least DarkGDK and DBPro don't share clock cycles with other applications readily (via sleep command or anything to my knowledge). This means that to get the best results - you need to devise a way to make it so that your computer is definately executing these processes in tandem/parallel. Hardware sharing (one disk drive - two processes) is a bottle neck kind of - plus hardware is just slow. Memory - not a big deal. Need dual core/dual processors or better still a quadcore to have the best chances of it working smoothly.

Something tells me if a game engine as slick as Far Cry didn't bother - and I haven't seen any actually pull it off yet - its probably not easy to do smoothly without video glitches, stutters, pauses etc.

My idea of a loader is that you can make an EXE that has one purpose in life - starting your game as an external child process (Execute - no wait... or basically shell out and start that game so it begins loading) and the loader would then load and start to "play" the movie... constantly polling if the media was done. You would need to devise a way for your game to tell the loader its ready. Alternatively - your loader could load the game and a separate process that plays the movie - this is your project - so you'll have to trudge thorugh various ideas and see what works best - you know the drill - but the idea has merit.

RPDan's methods might make it easier to force the parallel processing you'll need - (I don't think you can choose a processor to "shell out" and launch an external program - probably can - but I don't know for certain but I DO know you should be able to select which processor you want your threads to run on. Typically this is done by via "Processor Affinity". In short you check which CPU is the most free (idle) than launch your thread there. There is no guarantee it will stay as "idle" or "free" as it was by the time your thread starts - but this is typically how its done.

Ta ta for now - and good luck. I don't envy you on this one. Me - I'm going for the splash screen - maybe a few level screen shots and the tried and true loading progress bar - you know - the kind that fills more than halfway in a few seconds - then seems to hang for a long time to get that last bit of the bar filled in? Yeah - one of those

unitech
17
Years of Service
User Offline
Joined: 27th Jun 2007
Location:
Posted: 2nd Oct 2007 14:41 Edited at: 2nd Oct 2007 14:41
RPDan,jason p sage thx. I'm actually attempting this. I found an excellent tutorial on the matter and it looks as though this is gong to work out nicely. I'll report back.

Login to post a reply

Server time is: 2024-11-19 16:25:10
Your offset time is: 2024-11-19 16:25:10