PresentationBufferAddFrame Method (MediaBufferByte, CancellationToken) |
Adds a new frame to the presentation buffer.
Namespace: StreamCodersAssembly: MediaBase (in MediaBase.dll) Version: 2.0.5.0 (2.0.5.0)
Syntaxpublic CodecOperationStatus AddFrame(
MediaBuffer<byte> pictureMediaBuffer,
CancellationToken cancellationToken
)
Public Function AddFrame (
pictureMediaBuffer As MediaBuffer(Of Byte),
cancellationToken As CancellationToken
) As CodecOperationStatus
public:
CodecOperationStatus AddFrame(
MediaBuffer<unsigned char>^ pictureMediaBuffer,
CancellationToken cancellationToken
)
member AddFrame :
pictureMediaBuffer : MediaBuffer<byte> *
cancellationToken : CancellationToken -> CodecOperationStatus
Parameters
- pictureMediaBuffer
- Type: StreamCodersMediaBufferByte
A picture media buffer. - cancellationToken
- Type: System.ThreadingCancellationToken
A cancellation token to abort a blocking operation if the output queues maximum length is reached.
Return Value
Type:
CodecOperationStatus
Remarks
Note that all presentationTime values fed to the presentation buffer have to be unique,
otherwise they may be overwritten.
When a maximum output queue count was specified this method will block until the number of items in the OutputQueue is reduced. The CancellationToken should be used to abort blocking operations.
See Also