Table of Contents

Class VP9ParseBlock

Namespace
VisioForge.Core.MediaBlocks.Parsers
Assembly
VisioForge.Core.dll

Parses VP9 video bitstreams for superframe boundary detection and codec parameter extraction.

public class VP9ParseBlock : MediaBlock, IMediaBlock, IDisposable, IMediaBlockInternals

Inheritance

Implements

Inherited Members

Extension Methods

Remarks

The VP9ParseBlock processes VP9 encoded video streams, parsing frame headers and superframe structures to ensure proper frame boundaries. VP9 is Google's open-source video codec offering efficient compression for web video, competing with H.265/HEVC while remaining royalty-free.

Key features: - Superframe parsing and frame boundary detection - Profile detection (0-3) including high bit depth support - Frame header parsing for resolution and reference frame info - Temporal and spatial scalability layer identification - Color space and HDR metadata extraction (BT.709, BT.2020, etc.) - Lossless compression mode detection - Show existing frame and invisible frame handling - Segmentation and tile boundary processing

Common use cases: - Streaming: Preparing VP9 for WebM/DASH adaptive streaming - Muxing: Packaging VP9 into WebM, MP4, or MKV containers - Web video: Processing VP9 content for HTML5 video playback - Transcoding: Providing properly parsed frames to VP9 decoders - YouTube: Handling VP9 streams from YouTube and similar platforms - WebRTC: Processing VP9 in real-time communication applications

The parser supports all VP9 profiles: - Profile 0: 8-bit 4:2:0 (most common) - Profile 1: 8-bit 4:2:2, 4:4:4 - Profile 2: 10/12-bit 4:2:0 - Profile 3: 10/12-bit 4:2:2, 4:4:4 It handles both traditional frame-based streams and superframe-packed formats commonly used in WebM containers.

Constructors

VP9ParseBlock()

Initializes a new instance of the VisioForge.Core.MediaBlocks.Parsers.VP9ParseBlock class.

public VP9ParseBlock()

Remarks

Creates input and output pads configured for video media type. The parser will automatically detect VP9 profile, bit depth, and color space information from the bitstream headers and handle superframe structures when present.

Properties

Input

Gets the primary input pad for receiving VP9 bitstream data.

public override MediaBlockPad Input { get; }

Property Value

MediaBlockPad

Inputs

Gets all input pads available on this block.

public override MediaBlockPad[] Inputs { get; }

Property Value

MediaBlockPad[]

Output

Gets the primary output pad that provides parsed VP9 frames.

public override MediaBlockPad Output { get; }

Property Value

MediaBlockPad

OutputPad

public MediaBlockPad OutputPad { get; }

Property Value

MediaBlockPad

Outputs

Gets all output pads available on this block.

public override MediaBlockPad[] Outputs { get; }

Property Value

MediaBlockPad[]

Type

Gets the type of this media block.

public override MediaBlockType Type { get; }

Property Value

MediaBlockType

Methods

Build()

Builds and initializes the VP9 parser element within the media pipeline.

public override bool Build()

Returns

bool

true if the parser was successfully created and configured; false if initialization failed or required plugins are missing.

Remarks

This method creates the GStreamer VP9 parser element, initializes it within the pipeline context, and connects the input/output pads. The parser will begin processing VP9 frames and superframes once the pipeline transitions to the playing state.

CleanUp()

Performs cleanup of the parser resources and resets the build state.

public void CleanUp()

Remarks

This method disposes of the GStreamer element and resets internal state. It is called during disposal to ensure proper resource cleanup.

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 the core GStreamer element wrapper.

public BaseElement GetCore()

Returns

BaseElement

The base element wrapper providing access to common GStreamer functionality.

GetElement()

Gets the underlying native GStreamer element.

public Element GetElement()

Returns

Element

The native GStreamer element instance used for VP9 frame parsing.

IsAvailable()

Determines whether the VP9 parser is available in the current GStreamer installation.

public static bool IsAvailable()

Returns

bool

true if the VP9 parser plugin is available; otherwise, false. This requires the GStreamer bad plugins to be installed.

Remarks

The VP9 parser is provided by the GStreamer bad plugins collection. Ensure the appropriate VisioForge SDK redistribution package is included in your project.

IMediaBlockInternals.SetContext(MediaBlocksPipeline)

Sets the media pipeline context for this block.

void IMediaBlockInternals.SetContext(MediaBlocksPipeline pipeline)

Parameters

pipeline MediaBlocksPipeline

The media pipeline that will contain this parser block.

See Also