Jump to content

[SOLVED] How to play video when loading World?


photo

Recommended Posts

Sorry for misunderstanding :D

 

Don't know if it's possible. I assume that in OilRush they load a really simple world that only plays videos and then load the "big" game world.

 

But loading screen with a video seems to be impossible right now ;)

Link to comment

engine.splash.setWorld

void engine.splash.setWorld(string name,int threshold = 0)

Description

Sets basic properties of a world splash screen, which is displayed while the world is being loaded. The splash screen can be either a two-part texture or a Flash movie (.swf). In case of the flash movie, it is played with its native FPS as the loading progress goes.

Notice

If NULL is set for a splash screen texture (and no Flash movie is used), LOADING text will be shown instead.

Arguments

 

string name - Name of the file with the world splash screen. If NULL (0) is passed, the splash screen is cleared.

int threshold = 0 - Amount of blur in the alpha channel when interpolating between states of the splash screen. This is an optional parameter; if it is not passed, 0 will be used instead.

 

Note the "or a Flash movie" part :D

Link to comment
Actually, Flash doesn't support video movies IIRC, but it's nice to have the ability to play flash files at loading :D
Note the "or a Flash movie" part ;)

 

Thanks.

 

But when use flash moive loading screen with "engine.splash",the fps was very low and unstable,just like loading bar...

 

Oil Rush game flow:

 

play video->loading world(static texture)-main UI->loading world(static texture)->play video->game play...

 

 

 

I just want use video to replace static texture when loading world...

Link to comment
Unfortunately, it's not possible right now (or I did not find it in the doc). Perhaps Unigine crew will add it to the next SDK, as it seems to be a trivial functionality ;)

 

Thank you all the same.

 

BTW:I think it's a very basic functionality ;)

Link to comment

No, sorry, adding video splashes is not planned.

 

Just in case, it's not trivial. If video is rendered in one thread where scripts are compiled and the world is loaded, lags are imminent. And it's not possible to render it in a separate thread, since OpenGl does not support having a rendering context in more then one thread. In DirectX it's possible. In OpenGL, alas, no.

Link to comment
×
×
  • Create New...