Class QTDemuxBlock
- Namespace
- VisioForge.Core.MediaBlocks.Sources
- Assembly
- VisioForge.Core.dll
QuickTime/MP4/MOV demultiplexer block for extracting individual streams from container files. This block parses QuickTime-based container formats (MP4, MOV, M4A, 3GP) and separates them into individual video, audio, subtitle, and metadata streams. Supports advanced features including fragmented MP4, multiple tracks, chapter information, and embedded metadata. Essential for playback applications, transcoding workflows, stream analysis, and any scenario requiring access to individual streams within QuickTime containers. Implements the VisioForge.Core.MediaBlocks.MediaBlock. Implements the VisioForge.Core.MediaBlocks.IMediaBlockInternals. Implements the IDisposable.
public class QTDemuxBlock : MediaBlock, IMediaBlock, IDisposable, IMediaBlockInternalsInheritance
Implements
Inherited Members
Extension Methods
Constructors
QTDemuxBlock(bool, bool, bool, bool)
Initializes a new instance of the VisioForge.Core.MediaBlocks.Sources.QTDemuxBlock class with configurable stream extraction options.
public QTDemuxBlock(bool renderVideo = true, bool renderAudio = true, bool renderSubtitle = false, bool renderMetadata = false)Parameters
renderVideobool-
if set to
trueextract and output video streams. renderAudiobool-
if set to
trueextract and output audio streams. renderSubtitlebool-
if set to
trueextract and output subtitle streams. renderMetadatabool-
if set to
trueextract and output metadata streams.
Properties
AudioOutput
Gets the audio output pad for extracted audio streams. Only available when audio rendering is enabled.
public MediaBlockPad AudioOutput { get; }Property Value
Input
Gets the input.
public override MediaBlockPad Input { get; }Property Value
Inputs
Gets the inputs.
public override MediaBlockPad[] Inputs { get; }Property Value
MetadataOutput
Gets the metadata output pad for extracted metadata streams. Only available when metadata rendering is enabled.
public MediaBlockPad MetadataOutput { get; }Property Value
Output
Gets the output.
public override MediaBlockPad Output { get; }Property Value
Outputs
Gets the outputs.
public override MediaBlockPad[] Outputs { get; }Property Value
SubtitleOutput
Gets the subtitle output pad for extracted subtitle streams. Only available when subtitle rendering is enabled.
public MediaBlockPad SubtitleOutput { get; }Property Value
Type
Gets the type.
public override MediaBlockType Type { get; }Property Value
VideoOutput
Gets the video output pad for extracted video streams. Only available when video rendering is enabled.
public MediaBlockPad VideoOutput { get; }Property Value
Methods
Build()
Constructs and initializes the QuickTime demux and associated queue elements. This method creates the demux element, sets up dynamic pad handlers for each stream type, creates queue elements for enabled streams, and establishes output pad connections.
public override bool Build()Returns
- bool
-
trueif the demux was successfully built and configured;falseif initialization failed.
CleanUp()
Releases all resources and performs cleanup operations for this QuickTime demux block. This method disposes of the demux element and all queue elements, then resets the build state.
public void CleanUp()Dispose(bool)
Releases unmanaged and - optionally - managed resources.
protected override void Dispose(bool disposing)Parameters
disposingbool-
trueto release both managed and unmanaged resources;falseto release only unmanaged resources.
GetCore()
Gets the core BaseElement wrapper. Returns null as the demux element is accessed directly without a wrapper.
public BaseElement GetCore()Returns
- BaseElement
-
Always returns null for this implementation.
GetElement()
Gets the underlying GStreamer element that performs the QuickTime demuxing.
public Element GetElement()Returns
- Element
-
The GStreamer Element instance representing the QT demux.
IsAvailable()
Determines whether this media block is available. Correct NuGet SDK redist should be included into your project.
public static bool IsAvailable()Returns
- bool
-
trueif this media block is available; otherwise,false.
IMediaBlockInternals.SetContext(MediaBlocksPipeline)
Associates this QuickTime demux block with a pipeline and initializes its internal context. This method is called internally when the block is added to a pipeline.
void IMediaBlockInternals.SetContext(MediaBlocksPipeline pipeline)Parameters
pipelineMediaBlocksPipeline-
The MediaBlocksPipeline instance that will manage this block.