epoc32/include/mmf/server/mmfdatapath.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
williamr@2
     1
// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@4
     4
// under the terms of "Eclipse Public License v1.0"
williamr@2
     5
// which accompanies this distribution, and is available
williamr@4
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
// source\server\mmfdatapath.h
williamr@2
    15
// 
williamr@2
    16
//
williamr@2
    17
williamr@2
    18
#ifndef MMFDATAPATH_H
williamr@2
    19
#define MMFDATAPATH_H
williamr@2
    20
williamr@2
    21
#include <mmf/common/mmfcontroller.h>
williamr@2
    22
#include <mmf/server/mmfdatasource.h>
williamr@2
    23
#include <mmf/server/mmfdatasink.h>
williamr@2
    24
#include <mmf/server/mmfcodec.h>
williamr@2
    25
#include <mmf/server/mmfbuffer.h>
williamr@2
    26
#include <mmf/common/mmfutilities.h>
williamr@2
    27
#include <mmf/server/mmfformat.h>
williamr@4
    28
#include <mmf/server/mmfsubthreadbase.h>
williamr@2
    29
williamr@2
    30
/**
williamr@2
    31
 * @publishedAll
williamr@2
    32
 * @deprecated
williamr@2
    33
 *
williamr@2
    34
 * Datapath general error code used when sending events to clients
williamr@2
    35
 */
williamr@2
    36
const TUid KMMFErrorCategoryDataPathGeneralError = {0x101F76DC};
williamr@2
    37
williamr@2
    38
williamr@2
    39
williamr@2
    40
/**
williamr@2
    41
@publishedAll
williamr@2
    42
@deprecated
williamr@2
    43
williamr@2
    44
Abstract utility class that moves data from a single data source to a single data sink, via a codec if required.
williamr@2
    45
williamr@2
    46
All functions are exported form the DLL and are virtual to allow plugins to define their own data paths.
williamr@2
    47
*/
williamr@2
    48
class CMMFDataPath : public CActive,
williamr@2
    49
					 public MDataSink,
williamr@2
    50
					 public MDataSource, 
williamr@2
    51
					 public MAsyncEventHandler
williamr@2
    52
	{ 
williamr@2
    53
public:
williamr@2
    54
williamr@2
    55
	//CMMFDataPath constructor if codec Uid is not already known by CMMFController
williamr@2
    56
	//and there is no data path ambiguity - ie only one data path is possible
williamr@2
    57
	IMPORT_C static CMMFDataPath* NewL(MAsyncEventHandler& aEventHandler); 
williamr@2
    58
williamr@2
    59
	//CMMFDataPath constructor if codec Uid is not already known by CMMFController
williamr@2
    60
	//and there is ambiguity ie more than one possible data path TMediaId used to select path 
williamr@2
    61
	IMPORT_C static CMMFDataPath* NewL(TMediaId aMediaId, MAsyncEventHandler& aEventHandler); 
williamr@2
    62
williamr@2
    63
	//CMMFDataPath constructor if codec Uid is already known by CMMFController
williamr@2
    64
	//and there is no data path ambiguity - ie only one data path is possible
williamr@2
    65
	IMPORT_C static CMMFDataPath* NewL(TUid aCodecUid, MAsyncEventHandler& aEventHandler); 
williamr@2
    66
williamr@2
    67
	//CMMFDataPath constructor if codec Uid is already known by CMMFController
williamr@2
    68
	//and there is ambiguity ie more than one possible data path TMediaId used to select path 
williamr@2
    69
	IMPORT_C static CMMFDataPath* NewL(TUid aCodecUid, TMediaId aMediaId, MAsyncEventHandler& aEventHandler);
williamr@2
    70
williamr@2
    71
	IMPORT_C virtual ~CMMFDataPath();
williamr@2
    72
williamr@2
    73
	// Called when source and sink needs to be de-referenced
williamr@2
    74
	IMPORT_C virtual void ResetL();
williamr@2
    75
williamr@2
    76
	//from MDataSink - CMMFData path is a sink to its MDataSource
williamr@2
    77
	IMPORT_C virtual void EmptyBufferL(CMMFBuffer* aBuffer, MDataSource* aSupplier, TMediaId aMediaId); //only required for an active push MDataSource requesting a buffer empty - not implemented
williamr@2
    78
	IMPORT_C virtual void BufferFilledL(CMMFBuffer* aBuffer); //called by the CMMFDataPath's MDataSource when it has filled the buffer
williamr@2
    79
	IMPORT_C virtual TBool CanCreateSinkBuffer(); //from both MDataSource & MDataSink?
williamr@2
    80
	IMPORT_C virtual CMMFBuffer* CreateSinkBufferL(TMediaId aMediaId); //CMMFDataPath can't create buffers
williamr@2
    81
	IMPORT_C virtual CMMFBuffer* CreateSinkBufferL(TMediaId aMediaId, TBool &aReference); //CMMFDataPath can't create buffers
williamr@2
    82
williamr@2
    83
	IMPORT_C virtual TFourCC SinkDataTypeCode(TMediaId aMediaId);
williamr@2
    84
williamr@2
    85
	//from MDataSource
williamr@2
    86
	IMPORT_C virtual void FillBufferL(CMMFBuffer* aBuffer, MDataSink* aConsumer, TMediaId aMediaId); //only required for an active pull MDataSink requesting buffer fill - not implementated
williamr@2
    87
	IMPORT_C virtual void BufferEmptiedL(CMMFBuffer* aBuffer);//called by the CMMFDataPath's MDataSink when it has emptied the buffer
williamr@2
    88
	IMPORT_C virtual TBool CanCreateSourceBuffer(); //from both MDataSource & MDataSink?
williamr@2
    89
	IMPORT_C virtual CMMFBuffer* CreateSourceBufferL(TMediaId aMediaId); //CMMFDataPath can't create buffers
williamr@2
    90
	IMPORT_C virtual CMMFBuffer* CreateSourceBufferL(TMediaId aMediaId, TBool &aReference); //CMMFDataPath can't create buffers
williamr@2
    91
	IMPORT_C virtual TFourCC SourceDataTypeCode(TMediaId aMediaId);
williamr@2
    92
williamr@2
    93
	IMPORT_C virtual void AddDataSourceL(MDataSource* aSource);
williamr@2
    94
	IMPORT_C virtual void AddDataSinkL(MDataSink* aSink);
williamr@2
    95
williamr@2
    96
	//could derive these from a mixin eg MMMFControle later for active MDataSource/Sinks
williamr@2
    97
	IMPORT_C virtual void PrimeL();
williamr@2
    98
	IMPORT_C virtual void PlayL();
williamr@2
    99
	IMPORT_C virtual void Pause();
williamr@2
   100
	IMPORT_C virtual void Stop();
williamr@2
   101
williamr@2
   102
	IMPORT_C virtual TTimeIntervalMicroSeconds Position() const;
williamr@2
   103
	IMPORT_C virtual void SetPositionL(const TTimeIntervalMicroSeconds& aPosition);
williamr@2
   104
williamr@2
   105
	// Play Window.
williamr@2
   106
	IMPORT_C virtual void SetPlayWindowL( const TTimeIntervalMicroSeconds& aStart, const TTimeIntervalMicroSeconds& aEnd ) ;
williamr@2
   107
	IMPORT_C virtual void ClearPlayWindowL() ;
williamr@2
   108
williamr@2
   109
	//State
williamr@2
   110
	IMPORT_C virtual TInt State();
williamr@2
   111
williamr@2
   112
	//CActive implementations
williamr@2
   113
	IMPORT_C void RunL();
williamr@2
   114
	IMPORT_C void DoCancel();
williamr@2
   115
	IMPORT_C TInt RunError(TInt aError);
williamr@2
   116
williamr@2
   117
	//error handling
williamr@2
   118
	IMPORT_C TInt DoSendEventToClient(TUid aEventType, TInt aErrorCode);
williamr@2
   119
williamr@2
   120
	IMPORT_C TInt SetBlockLength(TUint aBlockLength);
williamr@2
   121
	/**
williamr@2
   122
	
williamr@2
   123
	Indicates the state of the data path.
williamr@2
   124
williamr@2
   125
	Mimics typical MultiMedia behaviour of stopped, primed and playing
williamr@2
   126
	*/
williamr@2
   127
	enum TDataPathState
williamr@2
   128
		{
williamr@2
   129
		/** Stopped.
williamr@2
   130
		*/
williamr@2
   131
		EStopped,
williamr@2
   132
		/** Primed.
williamr@2
   133
		*/
williamr@2
   134
		EPrimed,
williamr@2
   135
		/** Playing.
williamr@2
   136
		*/
williamr@2
   137
		EPlaying,
williamr@2
   138
		/** Recording.
williamr@2
   139
		*/
williamr@2
   140
		ERecording,
williamr@2
   141
		/** Converting.
williamr@2
   142
		*/
williamr@2
   143
		EConverting
williamr@2
   144
		};
williamr@2
   145
williamr@2
   146
	/**
williamr@2
   147
	@internalComponent
williamr@2
   148
	*/
williamr@2
   149
	class CCompleteCallback : public CActive
williamr@2
   150
		{
williamr@2
   151
	public:
williamr@2
   152
		CCompleteCallback(CMMFDataPath& aDataPath, TBool aWaitForSink);
williamr@2
   153
		~CCompleteCallback();
williamr@2
   154
williamr@2
   155
		void SignalDataPathComplete(TInt aDataPathError);
williamr@2
   156
		void SignalSinkComplete(TInt aSinkError);
williamr@2
   157
		TRequestStatus& ActiveStatus();
williamr@2
   158
williamr@2
   159
		void DoCancel();
williamr@2
   160
	private:
williamr@2
   161
		void RunL();
williamr@2
   162
		CMMFDataPath& iDataPath;
williamr@2
   163
		TBool iDataPathComplete;
williamr@2
   164
		TBool iSinkComplete;
williamr@2
   165
		TBool iWaitForSink;
williamr@2
   166
williamr@2
   167
		TInt iSinkError;
williamr@2
   168
		TInt iDataPathError;
williamr@2
   169
		};
williamr@2
   170
	friend class CCompleteCallback;
williamr@2
   171
	friend class CMMFDataPath2;
williamr@2
   172
protected:
williamr@2
   173
williamr@2
   174
	/**
williamr@2
   175
	Indicates the transfer state.
williamr@2
   176
	
williamr@2
   177
	Buffers maybe be filled, emptied, or have "one" shot initialisatings performed upon them.
williamr@2
   178
	
williamr@2
   179
	TTransferState is used within the datapath RunL which drives databuffer exchange.
williamr@2
   180
	*/
williamr@2
   181
	enum TTransferState
williamr@2
   182
		{
williamr@2
   183
		/** Waiting on a BufferEmptied callback from sink
williamr@2
   184
		*/
williamr@2
   185
		EWaitSink,
williamr@2
   186
		/** Waiting on a BufferFilled callback from source
williamr@2
   187
		*/
williamr@2
   188
		EWaitSource,
williamr@2
   189
		/** Initialize the sink.
williamr@2
   190
		*/
williamr@2
   191
		EInitializeSink,
williamr@2
   192
		/** Initialize the source.
williamr@2
   193
		*/
williamr@2
   194
		EInitializeSource,
williamr@2
   195
		/** Source buffer does not contain data.
williamr@2
   196
		*/
williamr@2
   197
		ENeedSourceData,
williamr@2
   198
		/** Sink buffer does not contain data.
williamr@2
   199
		*/
williamr@2
   200
		ENeedSinkData,
williamr@2
   201
		/** There is more source data to send to the sink and need to match sink and source.
williamr@2
   202
		*/
williamr@2
   203
		ENeedToMatchSourceToSink,
williamr@2
   204
		/** Outstanding data to send to sink.
williamr@2
   205
		*/
williamr@2
   206
		ESendDataToSink,
williamr@2
   207
		/** End of data.
williamr@2
   208
		*/
williamr@2
   209
		EEndOfData //indicates that the datapath has transferred all the data to the sink
williamr@2
   210
		};
williamr@2
   211
williamr@2
   212
williamr@2
   213
williamr@2
   214
williamr@2
   215
protected:
williamr@2
   216
	CMMFDataPath(TMediaId aMediaId, MAsyncEventHandler& aEventHandler) : 
williamr@2
   217
		CActive(EPriorityStandard), MDataSink(KUidMmfDataPath), MDataSource(KUidMmfDataPath),
williamr@2
   218
		iEventHandler(aEventHandler), iMediaId(aMediaId), iState(EStopped) 
williamr@2
   219
			{CActiveScheduler::Add(this);};
williamr@2
   220
williamr@2
   221
	IMPORT_C void ConstructL(TUid aCodecUid = KNullUid);
williamr@2
   222
	IMPORT_C virtual void ConstructSourceL( const TDesC8& aInitData ) ;
williamr@2
   223
	IMPORT_C virtual void ConstructSinkL( const TDesC8& aInitData ) ;
williamr@2
   224
	IMPORT_C virtual void EndOfData();
williamr@2
   225
williamr@2
   226
	//These methods use API on DevSound to determine how many samples have been played/recorded
williamr@2
   227
	//and thereby determine the real position.
williamr@2
   228
	TTimeIntervalMicroSeconds CalculateAudioOutputPosition() const;
williamr@2
   229
	TTimeIntervalMicroSeconds CalculateAudioInputPosition() const;
williamr@2
   230
williamr@2
   231
	//These methods determine the position of either the input or the output.
williamr@2
   232
	//The position may come from a format or from an audio input/output depending on 
williamr@2
   233
	//the operation the datapath is doing (Playing (output), Recording & Converting (input))
williamr@2
   234
	TTimeIntervalMicroSeconds OutputPosition() const;
williamr@2
   235
	TTimeIntervalMicroSeconds InputPosition() const;
williamr@2
   236
williamr@2
   237
williamr@2
   238
	//Determines what buffers are required (see TNeedBuffer)
williamr@2
   239
	//May leave KErrNotSupported if source/sinks can't supply the necessary buffers
williamr@2
   240
	TInt DetermineBuffersToUseL(void) const; 
williamr@2
   241
williamr@2
   242
	//Determines how many samples have been played by DevSound
williamr@2
   243
	TInt AudioSamplesPlayed() const;
williamr@2
   244
williamr@2
   245
	//Determines how many samples have been recorded by DevSound
williamr@2
   246
	TInt AudioSamplesRecorded() const;
williamr@2
   247
williamr@2
   248
williamr@2
   249
private:
williamr@2
   250
	void ChangeDataPathTransferState(TTransferState aNewDataPathTransferState);
williamr@2
   251
	void CreateDataPathL(MDataSource* aSource, MDataSink* aSink);
williamr@2
   252
	
williamr@2
   253
	void InitializeSinkL();
williamr@2
   254
	void InitializeSourceL();
williamr@2
   255
	void FillSourceBufferL();
williamr@2
   256
	void FillSinkBufferL();
williamr@2
   257
	void EmptySinkBufferL();
williamr@2
   258
	void DoCleanupBuffers();
williamr@2
   259
	void ObtainSyncBuffersL(); //tries to obtain synchronous data buffers from src/snk
williamr@2
   260
williamr@2
   261
	TTimeIntervalMicroSeconds Duration() const;
williamr@2
   262
williamr@2
   263
	void DoStopL();
williamr@2
   264
	void DoPauseL();
williamr@2
   265
	void DoEndOfDataL();
williamr@2
   266
williamr@2
   267
	IMPORT_C TInt SendEventToClient(const TMMFEvent& aEvent);
williamr@2
   268
williamr@2
   269
	void SetBuffersAvailable();
williamr@2
   270
	void ResetRefBuffers();
williamr@2
   271
williamr@2
   272
	
williamr@2
   273
williamr@2
   274
protected:
williamr@2
   275
	/**
williamr@2
   276
    Event handler.
williamr@2
   277
	*/
williamr@2
   278
	MAsyncEventHandler& iEventHandler;
williamr@2
   279
williamr@2
   280
	/** 
williamr@2
   281
	The source of data to which the CMMFDataPath is a MDataSink for.
williamr@2
   282
	*/
williamr@2
   283
	MDataSource* iDataSource;
williamr@2
   284
	/** 
williamr@2
   285
	The sink of data for which the CMMFDataPath is a MDataSource for
williamr@2
   286
	*/
williamr@2
   287
	MDataSink* iDataSink;
williamr@2
   288
	/** 
williamr@2
   289
	Set to true when the sink is able to accept data. EFalse otherwise.
williamr@2
   290
	*/
williamr@2
   291
	TBool iSinkCanReceive;
williamr@2
   292
	/**
williamr@2
   293
	The sink's data type. Same as the codec input data type.
williamr@2
   294
	*/
williamr@2
   295
	TFourCC iSinkFourCC;
williamr@2
   296
	/** 
williamr@2
   297
	The source's data type. Same as the codec output data type.
williamr@2
   298
	*/
williamr@2
   299
	TFourCC iSourceFourCC;
williamr@2
   300
	/** 
williamr@2
   301
	Identifies which media type and stream within MDataSource.
williamr@2
   302
	*/
williamr@2
   303
	TMediaId iMediaId;
williamr@2
   304
	/** 
williamr@2
   305
	Codec in use. Null Codec is signified by == NULL
williamr@2
   306
	*/
williamr@2
   307
	CMMFCodec* iCodec;
williamr@2
   308
williamr@2
   309
	/**
williamr@2
   310
    Result of processing the codec.
williamr@2
   311
	*/
williamr@2
   312
	TCodecProcessResult iCodecProcessResult;
williamr@2
   313
williamr@2
   314
	/**
williamr@2
   315
	Set to ETrue when the data path has a source and a sink and can send data from the source to the sink.
williamr@2
   316
	*/
williamr@2
   317
	TBool iDataPathCreated;
williamr@2
   318
	
williamr@2
   319
	/**
williamr@2
   320
	Current data path state. 
williamr@2
   321
	@see TDataPathState	
williamr@2
   322
	*/
williamr@2
   323
	TDataPathState iState;
williamr@2
   324
williamr@2
   325
	/**
williamr@2
   326
    Current transfer state.
williamr@2
   327
	@see TTransferState
williamr@2
   328
	*/
williamr@2
   329
	TTransferState iTransferState;
williamr@2
   330
williamr@2
   331
	/**
williamr@2
   332
	Set to true if data path has to use a supplied codec in its construction.
williamr@2
   333
	*/
williamr@2
   334
	TBool iUseSuppliedCodecUid;
williamr@2
   335
williamr@2
   336
	/** 
williamr@2
   337
	This is set to point to whichever sink buffer is in use.
williamr@2
   338
	*/
williamr@2
   339
	CMMFBuffer* iSinkBuffer;
williamr@2
   340
williamr@2
   341
	/**
williamr@2
   342
	This is the pointer to whichever source buffer is in use
williamr@2
   343
	*/
williamr@2
   344
	CMMFBuffer* iSourceBuffer;
williamr@2
   345
williamr@2
   346
	/**
williamr@2
   347
	The source's position in terms of frames or some other time fixed parameter.
williamr@2
   348
	*/
williamr@2
   349
	TUint iCurrentSourceFrameNumber;
williamr@2
   350
williamr@2
   351
	/**
williamr@2
   352
	The sink's position in terms of frames or some other time fixed parameter.
williamr@2
   353
	*/
williamr@2
   354
	TUint iCurrentSinkFrameNumber;
williamr@2
   355
williamr@2
   356
	/**
williamr@2
   357
	Indicates that all data has been obtained from the source (ETrue if there is no more source data).
williamr@2
   358
	*/
williamr@2
   359
	TBool iNoMoreSourceData;
williamr@2
   360
williamr@2
   361
	/** 
williamr@2
   362
	Indicates that all data has been sent to the sink.
williamr@2
   363
	*/
williamr@2
   364
	TBool iAllDataSentToSink;
williamr@2
   365
williamr@2
   366
	/** 
williamr@2
   367
	Datapath completed because of an error; usually KErrNone.
williamr@2
   368
	*/
williamr@2
   369
	TUint iDataPathCompletedErrorCode;
williamr@2
   370
williamr@2
   371
	/**
williamr@2
   372
	Start position of the play window.
williamr@2
   373
	*/
williamr@2
   374
	TTimeIntervalMicroSeconds iPlayWindowStartPosition ;
williamr@2
   375
	
williamr@2
   376
	/**
williamr@2
   377
	End position of the play window.
williamr@2
   378
	*/
williamr@2
   379
	TTimeIntervalMicroSeconds iPlayWindowEndPosition ;
williamr@2
   380
williamr@2
   381
	/**	
williamr@2
   382
	The position audio will start playing from.
williamr@2
   383
	When stopping, this is set to iPlayWindowStartPosition.
williamr@2
   384
	When pausing, this is set to the current position.
williamr@2
   385
	*/
williamr@2
   386
	TTimeIntervalMicroSeconds iStartPosition;
williamr@2
   387
williamr@2
   388
	/**	
williamr@2
   389
	This value can be used to obtain the duration of the source when playing or converting.
williamr@2
   390
	This is an optimisation as this value will not change if we are playing or converting.
williamr@2
   391
	*/
williamr@2
   392
	TTimeIntervalMicroSeconds iCachedSourceDuration;
williamr@2
   393
williamr@2
   394
williamr@2
   395
	/** 
williamr@2
   396
	ETrue if the source buffer is reference to object owned by someone else.
williamr@2
   397
	*/
williamr@2
   398
	TBool iSrcBufRef;
williamr@2
   399
williamr@2
   400
	/**
williamr@2
   401
	ETrue if sink buffer is reference to object owned by someone else
williamr@2
   402
	*/
williamr@2
   403
	TBool iSnkBufRef;
williamr@2
   404
williamr@2
   405
	/**
williamr@2
   406
	Indicates asynchrous buffers from AudioInput.
williamr@2
   407
	*/
williamr@2
   408
	TBool iObtainingAsyncSourceBuffer;
williamr@2
   409
williamr@2
   410
	/**
williamr@2
   411
	Indicates asynchrous buffers from AudioOutput.
williamr@2
   412
	*/
williamr@2
   413
	TBool iObtainingAsyncSinkBuffer;
williamr@2
   414
williamr@2
   415
	/** 
williamr@2
   416
	Indicates DoPauseL() has been called.
williamr@2
   417
	*/
williamr@2
   418
	TBool iPauseCalled;
williamr@2
   419
williamr@2
   420
	/**	
williamr@2
   421
	Flag to indicate that a buffer is with the source.
williamr@2
   422
williamr@2
   423
	This is necessary as it is imperrative that when a buffer is with the source, it must
williamr@2
   424
	not be referenced in any way. The reason for this is that it is not mandated that sources
williamr@2
   425
	maintain buffer references. For example, it is valid for DevSound to return recorded data in a
williamr@2
   426
	different buffer to the one supplied to it.
williamr@2
   427
    */
williamr@2
   428
	TBool iSourceBufferWithSource;
williamr@2
   429
williamr@2
   430
	/**
williamr@2
   431
	Flag to indicate that a buffer is with the sink.
williamr@2
   432
williamr@2
   433
	This are necessary as it is imperrative that when a buffer is with the sink, it must
williamr@2
   434
	not be referenced in any way. The reason for this is that it is not mandated that sinks
williamr@2
   435
	maintain buffer references. For example, it is valid for DevSound to request more audio data in a
williamr@2
   436
	different buffer to the one supplied to it.
williamr@2
   437
	*/
williamr@2
   438
	TBool iSinkBufferWithSink;
williamr@2
   439
williamr@2
   440
williamr@2
   441
	/** 
williamr@2
   442
	Holds the number of samples played on audio output at a point where we
williamr@2
   443
	want to reference play duration from.
williamr@2
   444
	*/
williamr@2
   445
	TInt iReferenceAudioSamplesPlayed;
williamr@2
   446
williamr@2
   447
	/** 
williamr@2
   448
	Holds the number of samples recorded from audio input at a point where we
williamr@2
   449
	want to reference record duration from.
williamr@2
   450
	*/
williamr@2
   451
	TInt iReferenceAudioSamplesRecorded;
williamr@2
   452
williamr@2
   453
	/** 
williamr@2
   454
	Pointer to internal callback completion class
williamr@2
   455
	*/
williamr@2
   456
	CCompleteCallback * iCompleteCallback;
williamr@2
   457
williamr@2
   458
	/**
williamr@2
   459
	This indicates what buffers are required in order to operate.
williamr@2
   460
	If a real Codec is in use, buffers are required from both source and sink,
williamr@2
   461
	else only one is required and source is preferred.
williamr@2
   462
	*/
williamr@2
   463
	enum TNeedBuffer
williamr@2
   464
		{
williamr@2
   465
		/** No buffers needed.
williamr@2
   466
		*/
williamr@2
   467
		ENoBuffers = 0x0,
williamr@2
   468
		/** Sink buffer needed.
williamr@2
   469
		*/
williamr@2
   470
		ENeedSinkBuffer = 0x01,
williamr@2
   471
		/** Source buffer needed.
williamr@2
   472
		*/
williamr@2
   473
		ENeedSourceBuffer = 0x10
williamr@2
   474
		};
williamr@2
   475
williamr@2
   476
	/** Holds the outcome of the call to DetermineBuffersToUseL
williamr@2
   477
	*/
williamr@2
   478
	TInt iBuffersToUse;
williamr@2
   479
	};
williamr@2
   480
williamr@2
   481
#endif
williamr@4
   482