Table of Contents

Class MOVSinkBlock

Namespace
VisioForge.Core.MediaBlocks.Sinks
Assembly
VisioForge.Core.dll

Implements a sink block for writing media to QuickTime MOV container files. Supports multiple video and audio tracks with Apple-compatible codecs.

public class MOVSinkBlock : MediaBlock, IMediaBlock, IDisposable, IMediaBlockInternals, IMediaBlockDynamicInputs

Inheritance

Implements

Inherited Members

Extension Methods

Remarks

The MOVSinkBlock creates QuickTime movie files (.mov), Apple's multimedia container format. Key features include: - Multiple video tracks with various codecs (H.264, ProRes, etc.) - Multiple audio tracks with different formats (AAC, PCM, etc.) - Chapter markers and metadata support - Fast-start optimization for web streaming - Professional video editing compatibility

MOV files are preferred for: - macOS and iOS compatibility - Professional video editing workflows - ProRes video storage - Multi-track editing projects - Broadcast and production environments

The sink supports various Apple-specific features: - Timecode tracks - Color space metadata - HDR information - Professional codec support

Common use cases: - Final Cut Pro compatible exports - Professional video archiving - Multi-angle video projects - High-quality video distribution

Constructors

MOVSinkBlock(MOVSinkSettings)

Initializes a new instance of the VisioForge.Core.MediaBlocks.Sinks.MOVSinkBlock class.

public MOVSinkBlock(MOVSinkSettings settings)

Parameters

settings MOVSinkSettings

The MOV file configuration including output path and encoding parameters.

Remarks

Ensure the output directory exists and has write permissions. Configure track settings before adding input pads.

Exceptions

ArgumentNullException

Thrown when settings is null.

Properties

Input

Gets the first input.

public override MediaBlockPad Input { get; }

Property Value

MediaBlockPad

Inputs

Gets the inputs.

public override MediaBlockPad[] Inputs { get; }

Property Value

MediaBlockPad[]

Output

Gets the output.

public override MediaBlockPad Output { get; }

Property Value

MediaBlockPad

Outputs

Gets the outputs.

public override MediaBlockPad[] Outputs { get; }

Property Value

MediaBlockPad[]

Settings

Gets or sets the MOV file creation settings.

public MOVSinkSettings Settings { get; set; }

Property Value

MOVSinkSettings

Remarks

Settings control:

  • Output filename and location
  • Fast-start mode for progressive download
  • Fragment duration for streaming
  • Metadata and tagging options
  • Codec-specific parameters for each track

Type

Gets the type.

public override MediaBlockType Type { get; }

Property Value

MediaBlockType

Methods

Build()

Builds this instance.

public override bool Build()

Returns

bool

true if successfull, false otherwise.

CleanUp()

Performs cleanup of resources used by the MOV sink.

public void CleanUp()

Remarks

This method finalizes the MOV file structure, writes all indexes, and ensures the file is properly closed for playback compatibility.

CreateNewInput(MediaBlockPadMediaType)

Creates a new input pad for adding a media track to the MOV file.

public MediaBlockPad CreateNewInput(MediaBlockPadMediaType mediaType)

Parameters

mediaType MediaBlockPadMediaType

The type of media track to add (video or audio).

Returns

MediaBlockPad

A new VisioForge.Core.MediaBlocks.MediaBlockPad for connecting the media stream.

Remarks

Each input pad represents a separate track in the MOV file. Video tracks should use compatible codecs like H.264, HEVC, or ProRes. Audio tracks typically use AAC, PCM, or Apple Lossless.

Dispose(bool)

Releases unmanaged and - optionally - managed resources.

protected override void Dispose(bool disposing)

Parameters

disposing bool

true to release both managed and unmanaged resources; false to release only unmanaged resources.

GetCore()

Gets core.

public BaseElement GetCore()

Returns

BaseElement

VisioForge.Core.GStreamer.Base.BaseElement.

GetElement()

Gets the element.

public Element GetElement()

Returns

Element

Gst.Element.

GetFilenameOrURL()

Gets the output filename for the MOV file.

public string GetFilenameOrURL()

Returns

string

The full path to the output MOV file.

GetInput(MediaBlockPadMediaType)

Gets the existing input.

public MediaBlockPad GetInput(MediaBlockPadMediaType mediaType)

Parameters

mediaType MediaBlockPadMediaType

Type of the media.

Returns

MediaBlockPad

MediaBlockPad.

IsAvailable()

Determines whether MOV file creation functionality is available on the current platform.

public static bool IsAvailable()

Returns

bool

true if MOV sink is available; otherwise, false. Requires GStreamer's qtmux element and compatible codecs.

Remarks

MOV support requires the GStreamer good plugins package. Some professional codecs like ProRes may require additional plugins.

SetFilenameOrURL(string)

Sets the output filename for the MOV file.

public void SetFilenameOrURL(string value)

Parameters

value string

The full path where the MOV file should be written.

Remarks

The file extension should be .mov for proper format recognition. Changing the filename after pipeline start requires a restart.

IMediaBlockInternals.SetContext(MediaBlocksPipeline)

Sets the context.

void IMediaBlockInternals.SetContext(MediaBlocksPipeline pipeline)

Parameters

pipeline MediaBlocksPipeline

The pipeline.

See Also