Messages in this topic - RSS

Home ? Tips & Tricks ? Transparent videos as textures in Muvizu

the topic is closed
05/09/2011 15:38:43

CrazyDaveMuvizu staff
CrazyDave
Posts: 118
The latest release of Muvizu has an experimental feature which is disabled by default. It allows users to import partially transparent video files and apply them to any texture. They look great when applied to backdrops and work well within the lighting engine, i.e. as the transparent areas change shape, the correct shadows will be cast. So, if a user had a swarm of bees flying about, each would cast the correct shadow. It also provides a way to include animated assets from other software if the right chroma-key techniques are used.

There are probably many ways to create acceptable video files, but this is one that worked for me.

First, edit Program Files\Muvizu\MuvizuGame\Config\DefaultGame.ini (or Program Files (x86)\Muvizu\MuvizuGame\Config\DefaultGame.ini for the 32-bit version on a 64-bit OS). Set bStripVideoAlpha to false. Restart Muvizu. If Windows will not let you edit the file (with an "access denied" message because it is in Program Files) then just copy it to your Desktop, edit it there and then copy it back on top of the original file.

Get latest 1.10.0 (experimental) version of VirtualDub from http://virtualdub.sourceforge.net/. The latest experimental version is necessary to deal with transparent .PNG images. It’s free software.

Use a graphics package to make a series of 32-bit PNG files, i.e. with an alpha channel. Paint.net (free software) and Photoshop would work. Adobe Premier or other video editing software would probably be the best for dealing with long image sequences and for chroma-key work. I used a batch command in Photoshop to cut the same region out of every image, but that was just to get something working. Name the files numerically, e.g. foo001.png, f002.png ...

In Virtual Dub, File->Open video file and select your first image.

In Video->Color Depth, select “Autoselect” and “Same as decompression format”.

In video->compression, select “(Uncompressed RGB/YCbCr)”. I tried every other codec I could get my hands on and none of them seemed to deal correctly with the alpha channel, leading to broken results when applied to a texture in Muvizu. It would be great to find one that worked, however, as the uncompressed video is a severe memory hog.

Set your frame rate (Video->Frame Rate) and any other filter effects desired. It may be necessary (depending on memory limitations in Muvizu) to downsample the video using the resize filter (Video->Filters... then “Add...” and select “resize”).

To export your video file, choose File->Save as AVI... then import as a texture in Muvizu. Can be applied to any object or character where there is a texture picker available.

Limitations:
- Memory hog due to uncompressed codec.
- Flipbook textures with low frame rates don’t work very well as there is some flickering between the separate images.

Any contributions to this thread are welcome, as are suggestions for future development. I believe that there will be a video tutorial to help so if you're struggling with this then keep an eye out for that.

Here's an example that I made:





Credit to JonBez for the original superhero video.


Good luck!

edited by CrazyDave on 06/09/2011
edited by CrazyDave on 06/09/2011
permalink
05/09/2011 22:32:38

toonaramaMuvizu mogulExperimental user
toonarama
Posts: 661
Hi Dave
I get an Access Denied message when I try and save the ini file - I do have administrator rights
thanks

Mick
permalink
05/09/2011 22:37:53

CrazyDaveMuvizu staff
CrazyDave
Posts: 118
toonarama wrote:
I get an Access Denied message when I try and save the ini file


Hiya Mick,
I think this is a standard Windows 7 annoyance, that it won't let you edit a file within your Program Files dirctory tree. I think you can get past it by copying the file to your Desktop, editing it there and copying the new version back on top of the original in Program Files\Muvizu...

Let me know if this is what was needed,
Cheers, Dave.
edited by CrazyDave on 05/09/2011
permalink
06/09/2011 08:38:31

toonaramaMuvizu mogulExperimental user
toonarama
Posts: 661
Thanks for that Dave, I'll give it a go tonight.
I managed to create a video with alpha transparency in Sony Home Studio but this only seems to be possible with uncompressed video too; so might be some sort of global restriction.

Can't wait to give it a try
permalink
the topic is closed

Home ? Tips & Tricks ? Transparent videos as textures in Muvizu