Vixen
02b45cc4
csharp
public sealed class VideoImporter

Reads a video's header at build time, so a game does not have to open the file to plan.

No guide page documents this yet — the page shows what the code says about itself.

As a importer

Extensions
.webm .mkv .mp4 .m4v .mov

Remarks

It does not decode, and it does not transcode. Every other importer turns a source format into a runtime one; this one copies the container and writes down what is in it. The reason is the same one that shapes the whole module: the engine ships no video codec, so there is no runtime format to turn anything into — a shipped video is the file, played by whatever decoder the game registered.

What the metadata is for. Everything in VideoClip is readable from the container, and reading it means opening the file — which is exactly what a game choosing between three cutscenes, or an editor drawing a list of them, does not want to do. More to the point, CodecId here is what lets a title find out it has no decoder for a clip before the cutscene was supposed to start, which is the difference between a fallback and a black screen.

MP4 is claimed and refused, deliberately. AudioImporter makes the same call and states the same reason: doc 08's table promises mp4, and an artist who drops one in and finds it silently became an unplayable byte blob has learned nothing. Claiming it and failing with the name of what is missing is the more useful of the two silences.

Fields and properties (1)

  • public override int Version

    Its own version. Bumping it invalidates every artefact it has ever produced, which is the whole mechanism for "I fixed the mip filter, re-import everything".

Methods (1)

Used by (2)

  • BuiltInImportersVixen.Editor.Assets
  • VideoImporterTestsVixen.Editor.Assets.Tests