VideoFrameBufferInit Class

The description of the pixels of a VideoFrame created from a buffer (https://w3c.github.io/webcodecs/#dictdef-videoframebufferinit).

public sealed class VideoFrameBufferInit

Constructors

NameDescription
VideoFrameBufferInit()

VideoFrameBufferInit()

  • Obsolete: Constructors of types with required members are not supported in this version of your compiler.
[Obsolete("Constructors of types with required members are not supported in this version of your compiler.", true)]
public VideoFrameBufferInit()

No documentation is available.

Properties

NameDescription
CodedHeightGets the height of the pixels in the buffer.
CodedWidthGets the width of the pixels in the buffer.
ColorSpaceGets the color space of the pixels (BT.709 for the YUV formats and sRGB for the RGB formats by default).
DisplayHeightGets the display height (the visible height by default, swapped with the width by a rotation of 90 or 270 degrees).
DisplayWidthGets the display width (the visible width by default, swapped with the height by a rotation of 90 or 270 degrees).
DurationGets the presentation duration in microseconds, or null.
FlipGets whether the frame is flipped horizontally after the rotation.
FormatGets the format of the pixels.
LayoutGets the offset and the stride of each plane in the buffer (tightly packed by default).
MetadataGets the metadata of the frame.
RotationGets the clockwise rotation in degrees, rounded to a multiple of 90.
TimestampGets the presentation timestamp in microseconds.
TransferGets the ArrayBuffer objects detached by the construction.
VisibleRectGets the visible rectangle (the coded rectangle by default).

CodedHeight

VideoFrame.cs

Gets the height of the pixels in the buffer.

public required uint CodedHeight { get; init; }

CodedWidth

VideoFrame.cs

Gets the width of the pixels in the buffer.

public required uint CodedWidth { get; init; }

ColorSpace

VideoFrame.cs

Gets the color space of the pixels (BT.709 for the YUV formats and sRGB for the RGB formats by default).

public VideoColorSpaceInit? ColorSpace { get; init; }

DisplayHeight

VideoFrame.cs

Gets the display height (the visible height by default, swapped with the width by a rotation of 90 or 270 degrees).

public uint? DisplayHeight { get; init; }

DisplayWidth

VideoFrame.cs

Gets the display width (the visible width by default, swapped with the height by a rotation of 90 or 270 degrees).

public uint? DisplayWidth { get; init; }

Gets the presentation duration in microseconds, or null.

public ulong? Duration { get; init; }

Gets whether the frame is flipped horizontally after the rotation.

public bool Flip { get; init; }

Gets the format of the pixels.

public required VideoPixelFormat Format { get; init; }

Gets the offset and the stride of each plane in the buffer (tightly packed by default).

public IReadOnlyList<PlaneLayout>? Layout { get; init; }

Gets the metadata of the frame.

public VideoFrameMetadata? Metadata { get; init; }

Gets the clockwise rotation in degrees, rounded to a multiple of 90.

public double Rotation { get; init; }

Timestamp

VideoFrame.cs

Gets the presentation timestamp in microseconds.

public required long Timestamp { get; init; }

Gets the ArrayBuffer objects detached by the construction.

public IReadOnlyList<object>? Transfer { get; init; }

VisibleRect

VideoFrame.cs

Gets the visible rectangle (the coded rectangle by default).

public DomRectInit? VisibleRect { get; init; }