My game has videos for it’s menu and credits, but those videos can’t seem to run smoothly enough… It’s always jaggy…
Does any of you has some great encoding technique that could help me get a cool High Def or near High Def experience but making it so that unity runs it smoothly?
From your description “not runing smoothly enough”, could be your system can’t keep up with the screen refresh (maybe),
as for being “jaggy” check to see how much it is being compressed in the Inpsector,
or if it is being stretched, causing jagged edges.
you can’t go high def with Unity reasonably as movies are handled by CPU and for HD as in 1080p you need a 3ghz core 2 duo / core i cpu class to even stand a chance.
But the first thing to make quality better is not to use Unity to convert the movie but a distinct converter. The easiest is Miro and its quality is significantly better than Unitys at lower to much lower filesizes.
Sorry for the Jaggy, the video has a really great definition, but it runs like a game running in low-fps, the problem is that I tested that in my laptop and though: “hey, must be this piece of crap” the I put it in my desktop:
i7
12gb Ram
Gforce GTX 260 1.7gb Ram
And no, it didn’t run smoothly, it kept beeing laggy…
I’ll try Miro, but I wanted some encoding tips, what kind of codec or compression format unity reads better and those things, I think my problem lies there.
Unity does not support any codec aside of Theora. So your problem on that end, if present, would lie within the fact that you think that there is a codec topic
anything else is converted and the movies are always cpu driven, not hardware accelerated like what you see in quicktime etc.
as such: optimally your movie is uncompressed high quality and then you send it through miro to be theora. that yields the best quality at lowest rate, this helps on performance.
But thats it, you won’t get 1080p movie playback smooth, depending on hardware already 720p is beyond what you can do.
Thats a bad idea, cause Unitys theora version is outdated, its conversion quality is extremely bad. You need to use 8000kbps profile in unity to compete with the 2000kbps you get from other tools or to compete with the auto-output from miro (free for win and mac just to mention) and thats a major filesize and runtime performance difference.
And you won’t see a deal with mpeg-la as you as dev would have to pay them for licensing (as with mp3).
But Bink would be nice especially as it works for all unity platforms with acceleration, unlike most other options (on iOS you need something with proper cpu etc acceleration or it is as bad as theora again as the real hw acceleration is limited to apples movie player)
So, Dreamora, you are saying compress before importing to Unity and use no compression inside of Unity?
Unity will display the video without further compression?
Its always compressed, there is no such thing as uncompressed, cause the movie will ALWAYS be in Ogg Theora format.
What I recommend is that you do the conversion to ogg theora outside in a tool that uses the current ogg theora library and converter as the quality is much better. Also you no longer need to import it then in unity which saves a lot of time in the end.
And as 3rd benefit: ogg theora movies can also be moved out and loaded through WWW (its the only movie format you can do that as its the only one unity supports at runtime)
Thank you for this.
I was having a rough time as a .mov movie of 9MB, which is bad enough, was coming into Unity Pro as 145MB AND much poorer quality.
As a result of your advice I found a free Quicktime plugin from xiph.org, amazingly managed to install it as it was designed for a much earlier OS than I’m running, and it worked.
The file exported from QuickTime 7 and came into Unity at 160MB but the Unity settings could take it down to 8MB and still have an acceptable quality. There was no way I could have got this to work even that well without your advice.