public sealed class VideoPlaybackA clip, opened: a player, its sound, and everything holding the file.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
The missing half of VideoClip. The importer writes down what is in a video and where its bytes are; this is what turns that record into something that plays. Without it a game has an address it cannot do anything with and has to know the file path anyway, which is the whole of what an address exists to avoid.
It owns what it opened and nothing else. Disposing this closes the demuxers and the streams under them and disposes the player; the Clip and the content source belong to the caller. The audio provider is not registered with a mixer here — that is the caller's, because a mixer is a thing a game has one of and this is not the place to guess which.
Fields and properties (4)
public VideoClip ClipWhat was opened.
public VideoPlayer PlayerThe picture.
public MatroskaAudioStreamDecoder? AudioThe sound, or null if there is none or nothing could decode it.
public string AudioUnavailableReasonWhy there is no Audio, or empty if there is.
Methods (4)
public static bool CanPlay(VideoClip clip)Whether a codec is registered for this clip's picture.
public static VideoPlayback Open(VideoClip clip, IVideoContentSource content, VideoPlaybackOptions? options = null)Opens a clip.
public bool FollowAudio(IAudioSampleProvider provider, TimeSpan offset = default(TimeSpan))Makes the picture follow the sound, if there is any.
public void Dispose()Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Used by (1)
- VideoPlaybackTestsVixen.Video.Tests