Unity handles a number of different video formats, although mp4 seems to be
the most commonly-used. This is from a discussion about formats I found
on-line:
H.264 for video with AAC for audio, typically found in .mp4, .m4v and .mov
files. VP8 vor video and Vorbis for audio, typically found in .webm files.
These are the codecs that will work in most situations, both in the editor
and in the target platform. H.264 is often the best choice as it is
supported in hardware on most platforms - with Android also supporting VP8
in hardware. However, we're trying to have support for whatever the editor
platform supports. For instance:
- On Windows, we're using Media Foundation for reading/transcoding movie
files.
- On OSX, we're using AVFoundation for reading/transcoding movie files.
- On all editor platforms, including Linux, we have a software version of
the VP8 video codec and Vorbis audio codec.
So in theory, all formats handled by these APIs are supported in the
editor. I'm saying "in theory" because we do have some filtering based
on filename extensions that may go away in the future (not sure yet).
At this time, here's the list:
- All editor platforms: ogv, vp8, webm
- Additionally, on Windows and OSX: mov, dv, mp4, m4v, mpg, mpeg
- Additionally, on Windows: avi, asf, wmf
We will try to lift some restrictions and simply let the platform's
native APIs tell us whether a given file format is supported, but this
ties into how Unity's asset pipeline works so we cannot simply claim
that every filename extension "might be a movie file", hence the
current limitation.
Also, I'm not sure, but you may have to install support for QuickTime on
Windows mahcines to play .mov files.