C# Класс HCS_Encoder.Inputs.Buffers.ImageBuffer

Наследование: IEncoderBuffer
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
ImageBuffer ( int Width, int Height ) : System

Prepare a set of buffers to accept the images. Incoming frames will be scaled to match the given width and height. For best results, capture and buffer sizes should match. Rescaling does not preserve aspect ratio.

LoadToFrame ( MediaFrame &Frame ) : void

Load the buffer into a MediaFrame for the encoder. IMPORTANT: You must call UnloadFrame after this method is called. For efficiency, unload as soon as possible.

RebufferCapturedFrames ( ) : void

Convert a captured YUV buffer into a scaled YUV buffer

UnloadFrame ( MediaFrame &Frame ) : void

Release memory previously locked by LoadToFrame()

WipeBuffer ( ) : void

Emergeny clear-out. Drop all queued frames

WipeBufferUntil ( double AbandonTime ) : void

Remove all frames captured before the given capture time. They will not be encoded.

Приватные методы

Метод Описание
RescaleBuffers ( TimedImage Src, TimedImage Dst ) : void
ScalePlane ( byte Src, byte Dst, int src_w, int src_h, int dst_w, int dst_h, bool HQ ) : void

Описание методов

ImageBuffer() публичный Метод

Prepare a set of buffers to accept the images. Incoming frames will be scaled to match the given width and height. For best results, capture and buffer sizes should match. Rescaling does not preserve aspect ratio.
public ImageBuffer ( int Width, int Height ) : System
Width int
Height int
Результат System

LoadToFrame() публичный Метод

Load the buffer into a MediaFrame for the encoder. IMPORTANT: You must call UnloadFrame after this method is called. For efficiency, unload as soon as possible.
public LoadToFrame ( MediaFrame &Frame ) : void
Frame MediaFrame
Результат void

RebufferCapturedFrames() публичный Метод

Convert a captured YUV buffer into a scaled YUV buffer
public RebufferCapturedFrames ( ) : void
Результат void

UnloadFrame() публичный Метод

Release memory previously locked by LoadToFrame()
public UnloadFrame ( MediaFrame &Frame ) : void
Frame MediaFrame
Результат void

WipeBuffer() публичный Метод

Emergeny clear-out. Drop all queued frames
public WipeBuffer ( ) : void
Результат void

WipeBufferUntil() публичный Метод

Remove all frames captured before the given capture time. They will not be encoded.
public WipeBufferUntil ( double AbandonTime ) : void
AbandonTime double
Результат void