author | Pat Downey <patd@symbian.org> |
Fri, 23 Jul 2010 16:58:44 +0100 | |
changeset 0 | bb31fbe78861 |
permissions | -rw-r--r-- |
0
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
1 |
/* |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
2 |
* Copyright (c) 2009 Aricent and/or its subsidiary(-ies). |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
3 |
* All rights reserved. |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
4 |
* This component and the accompanying materials are made available |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
5 |
* under the terms of the License "Eclipse Public License v1.0" |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
6 |
* which accompanies this distribution, and is available |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html". |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
8 |
* |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
9 |
* Initial Contributors: |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
10 |
* Aricent - initial contribution. |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
11 |
* |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
12 |
* Contributors: |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
13 |
* |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
14 |
* Description: |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
15 |
* Declares interface class MBaseCodec whose pure virtual functions should be |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
16 |
* implemented by all video encoder/decoder wrappers |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
17 |
* |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
18 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
19 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
20 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
21 |
#ifndef ARIBASECODEC_H |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
22 |
#define ARIBASECODEC_H |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
23 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
24 |
#include <E32def.h> |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
25 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
26 |
class MBaseCodec |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
27 |
{ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
28 |
public: |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
29 |
/** |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
30 |
* This enumeration should be used to indicate the result |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
31 |
* of a call to DoProcessL |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
32 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
33 |
enum TCodecState { |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
34 |
EInputConsumed, |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
35 |
EOutputConsumed, |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
36 |
EConsumed, |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
37 |
ENotConsumed |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
38 |
}; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
39 |
public: |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
40 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
41 |
/** |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
42 |
* Processes an input buffer , returns one of the TCodecState |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
43 |
* @param aInpBuf |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
44 |
* Coded input data |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
45 |
* @param aOutBuf |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
46 |
* Decoded output data |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
47 |
* @leave The method will leave if an error occurs |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
48 |
* @return one of the TCodecState members |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
49 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
50 |
virtual TInt DoProcessL( TAny *aInpBuf, TAny* aOutBuf = NULL ) = 0; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
51 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
52 |
/** |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
53 |
* Used to set codec parameteres |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
54 |
* @param aCommand |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
55 |
* Indicates the encoder parameter to set |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
56 |
* @param aCmdData |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
57 |
* The value to which the encoder parameter should be set |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
58 |
* @return symbian wide error code |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
59 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
60 |
virtual TInt SetParam( TInt aCommand, TAny* aCmdData ) = 0; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
61 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
62 |
/** |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
63 |
* Used to get codec parameteres |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
64 |
* @param aCommand |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
65 |
* Indicates the encoder parameter to get |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
66 |
* @param aCmdData |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
67 |
* The value of the encoder parameter (OUT) |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
68 |
* @return symbian wide error code |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
69 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
70 |
virtual TInt GetParam( TInt aCommand, TAny* aCmdData ) = 0; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
71 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
72 |
/** |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
73 |
* Cancels all processing of the commands |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
74 |
*/ |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
75 |
virtual void Reset() = 0; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
76 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
77 |
}; |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
78 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
79 |
#endif //ARIBASECODEC_H |
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
80 |
|
bb31fbe78861
Initial commit of Aricent codec contribution.
Pat Downey <patd@symbian.org>
parents:
diff
changeset
|
81 |