TVideoFrameBuffer Class Reference

class TVideoFrameBuffer

TVideoFrameBuffer represents a buffer for a single decoded video picture. The buffer must be contained within a chunk that can be shared across processes.

The frame buffer class is used both for video renderer data flow and with the MMMFVideoClientBufferSupport extension.

Constructor & Destructor Documentation

TVideoFrameBuffer(const TUncompressedVideoFormat &, TInt, TInt, const RChunk &, TInt)

IMPORT_C TVideoFrameBuffer ( const TUncompressedVideoFormat & aFormat,
TInt aStride,
TInt aBufferId,
const RChunk & aChunk,
TInt aOffsetInChunk
)

Constructor

Parameters

const TUncompressedVideoFormat & aFormat Data format for the buffer.
TInt aStride Stride for the buffer, i.e. the number of bytes from the start of one pixel row to the next.
TInt aBufferId Buffer identifier, set by the buffer allocator. Buffer IDs are used to identify buffers in e.g. buffer rendering notifications.
const RChunk & aChunk The chunk where the buffer is located. Note that the TVideoFrame Buffer does not take ownership of the RChunk.
TInt aOffsetInChunk Offset from the beginning of the chunk for this buffer, in bytes.

Member Functions Documentation

Buffer()

IMPORT_C TUint8 * Buffer ( ) const

Returns a pointer to buffer data as mapped to the current process s address space.

BufferId()

IMPORT_C TInt BufferId ( ) const

Returns the buffer identifier of the buffer. Buffer IDs are used to identify buffers.

BufferStatus()

TBufferStatus BufferStatus ( ) const

Returns the buffer status.

Chunk()

IMPORT_C const RChunk & Chunk ( ) const

Returns the RChunk where the buffer is located. The RChunk can be shared between several TVideoFrameBuffers.

DblQueLink()

TDblQueLink & DblQueLink ( )

Returns the queue link for use by video renderer.

Format()

IMPORT_C TUncompressedVideoFormat Format ( ) const

Returns the data format of the buffer. For YUV formats, typically only TUncompressedVideoFormat.iYuvFormat.iDataLayout and iPattern are valid.

PresentationTime()

TTime PresentationTime ( ) const

Returns presentation time.

SetBufferStatus(TBufferStatus)

void SetBufferStatus ( TBufferStatus aStatus )

Set buffer status.

Parameters

TBufferStatus aStatus Buffer status set by video renderer

SetPresentationTime(const TTime &)

void SetPresentationTime ( const TTime & aTime )

Set presentation time.

Parameters

const TTime & aTime Presentation time

Stride()

IMPORT_C TUint Stride ( ) const

Returns the stride of the buffer. This is the number of bytes from the start of one pixel row to the next. The stride is commonly equal to bytes_per_pixel*width, but can be larger if the buffer requires padding. With planar YUV data the stride refers to luminance (Y) stride. Chrominance (U & V) stride is iStride/2.

Member Enumerations Documentation

Enum TBufferStatus

Status used by video renderer

Enumerators

EAvailable
EUsedByClient
EWaiting
ESubmitted

Member Data Documentation

TInt iBufferId

TInt iBufferId [private]

RChunk iChunk

RChunk iChunk [private]

TDblQueLink iDblQueLink

TDblQueLink iDblQueLink [private]

TUncompressedVideoFormat iFormat

TUncompressedVideoFormat iFormat [private]

const TInt iOffset

const TInt iOffset [static]

Offset for link list

TInt iOffsetInChunk

TInt iOffsetInChunk [private]

TTime iPresentationTime

TTime iPresentationTime [private]

TBufferStatus iStatus

TBufferStatus iStatus [private]

TInt iStride

TInt iStride [private]