Page 1 of 1

async movie texture

Posted: 12 Jan 2016, 17:06
by sandercox
We have a movie that is loading updating to load a next movie by changing the URI. The load of the movie takes a little to long and is causing render stalls so we figured we turn on async. Now the renderer continues but the movie texture is briefly white (while loading the new texture).

Could this be changed such that while loading a new movie the texture is only updated when the movie is ready and the last frame from the last movie remains in the texture during reload? That way the only noticeable change would be a short freeze on the old movie but we wouldn't see the white flash.

Re: async movie texture

Posted: 14 Jan 2016, 11:00
by Götz_B
Here is a little trick to avoid the white flash:
You can use a MultiSwitch with a Texture output. Set the operation to FirstValid. FirstValid means that the first texture input that is valid is set as output ('First' based on the Index, starting at 0, NOT 'first' in terms of time).
When you now bind your sources to input 0, you can bind a 'fallback' texture (for example a transparent texture) to input 1. So everytime you see now the white flash, you would see your fallback texture.

I know that this still doesn't bring you the last frame of the video, but maybe it helps.

Re: async movie texture

Posted: 14 Jan 2016, 12:09
by Karol
Another solution could be to use two player in an A/B mode.

Re: async movie texture

Posted: 14 Jan 2016, 12:28
by sandercox
True I could build an A/B container node that does the magic for this but figured it be fairly easy for a texture not to be destroyed before the next one is ready preventing noticeable glitches, a 3 frame freeze is less noticeable. But thanks for the suggestions