Table of Contents

Interface IEncoder

Namespace
VAST.Media
Assembly
VAST.Common.dll

Defines the contract for a media encoder that converts uncompressed media samples to compressed format.

public interface IEncoder : IDisposable
Inherited Members

Properties

IsUsable

Gets a value indicating whether the encoder is usable and properly initialized.

bool IsUsable { get; }

Property Value

bool

OutputMediaType

Gets the output media type describing the encoded format.

MediaType OutputMediaType { get; }

Property Value

MediaType

PlatformContext

Gets or sets the platform-specific encoder context.

object PlatformContext { get; set; }

Property Value

object

Methods

Drain()

Drains any remaining samples from the encoder's internal buffers.

void Drain()

Read()

Reads an encoded sample from the encoder.

VersatileBuffer Read()

Returns

VersatileBuffer

The encoded sample, or null if no sample is available.

Write(VersatileBuffer)

Writes an uncompressed media sample to the encoder for processing.

void Write(VersatileBuffer packet)

Parameters

packet VersatileBuffer

The uncompressed media sample to encode.