Location:
mmfdatabuffer.h
Link against: mmfserverbaseclasses.lib
class CMMFDescriptorBuffer : public CMMFDataBuffer;
This class is a wrapper class to give a descriptor the same API as a CMMFDataBuffer
.
The purpose of this class is that components such as codecs can use CMMFDataBuffers transparently without having to be concerned with whether the buffer is a descriptor buffer or a transfer buffer.
CBase
- Base class for all classes to be instantiated on the heap
CMMFBuffer
- Abstract representation of a buffer to contain multimedia data
CMMFDataBuffer
- This class is an abstract class for databuffers that can be presented in the form of a descriptor
CMMFDescriptorBuffer
- This class is a wrapper class to give a descriptor the same API as a
Defined in CMMFDescriptorBuffer
:
BufferSize()
, Data()
, Data()
, NewL()
, NewL()
, ReAllocBufferL()
, SetPosition()
, SetRequestSizeL()
, SetStatus()
, ~CMMFDescriptorBuffer()
Inherited from CBase
:
Delete()
,
Extension_()
,
operator new()
Inherited from CMMFBuffer
:
FrameNumber()
,
IsFileServerSafe()
,
IsSupportedDataBuffer()
,
LastBuffer()
,
NextFrame()
,
Position()
,
RequestSize()
,
SetFrameNumber()
,
SetLastBuffer()
,
SetTimeToPlay()
,
Status()
,
TimeToPlay()
,
Type()
,
iFrameNumber
,
iLastBuffer
,
iPosition
,
iRequestSize
,
iStatus
,
iTimeToPlay
,
iType
static IMPORT_C CMMFDescriptorBuffer *NewL();
Method to instantiate a CMMFDescriptorBuffer.
Defaults to a CMMFDescriptorBuffer automatically. This NewL creates a CMMFDescriptorBuffer with a default size of 32 bytes.
|
static IMPORT_C CMMFDescriptorBuffer *NewL(TInt aMaxBufferSize);
Method to instantiate a CMMFDescriptorBuffer. This NewL creates a CMMFDescriptorBuffer with a size of aMaxBufferSize bytes.
|
|
IMPORT_C ~CMMFDescriptorBuffer();
Destructor.
Destructor also deletes the buffer contained in the CMMFDescriptorBuffer.
IMPORT_C void ReAllocBufferL(TInt aMaxBufferSize);
Reallocates the max size in bytes of a CMMFDescriptorBuffer.
|
virtual TDes8 &Data();
Returns a descriptor to the data contained in the CMMFDescriptorBuffer.
|
virtual const TDesC8 &Data() const;
Returns a descriptor to the data contained in the CMMFDescriptorBuffer.
|
virtual void SetStatus(TBufferStatus aStatus);
Overriden method to set the status and resets the data size to 0 when the buffer becomes available.
|
virtual void SetRequestSizeL(TInt aSize);
Sets the request size.
This function is used in cases where a component (eg a data source) may not be able or be desirable to write to the entire
max length of the buffer (eg variable bit rate codecs). In which case the SetRequestSizeL()
can be set which can be read by the RequestSize()
function in the component so that it knows to only write data upto the request size and not fill the buffer up to its max
length.
|
virtual TUint BufferSize() const;
Returns the actual data size (ie. not the maximum length) of the data contained in the CMMFDescriptorBuffer.
|
virtual void SetPosition(TUint aPosition);
Sets the position.
This method is used by components (eg codecs) which read data from a buffer and wish to store a read position marker for further reads. Note: The position cannot exceed the size of the actual data not the max length.
|