mp4sp_enc/arimp4spencwrapper/export_hdr/arimp4spencwrapper.h
changeset 0 bb31fbe78861
equal deleted inserted replaced
-1:000000000000 0:bb31fbe78861
       
     1 /*
       
     2 * Copyright (c) 2009 Aricent and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Aricent - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 * Export header file for wrapper APIs.Interface class for
       
    16 * Mpeg4SP/H263 encoder wrapper.The member functions are pure virtual functions
       
    17 * which are to be implemented by the derived class.
       
    18 *
       
    19 */
       
    20 
       
    21 
       
    22 #ifndef ARIMP4SPENCWRAPPER_H
       
    23 #define ARIMP4SPENCWRAPPER_H
       
    24 
       
    25 //	INCLUDES
       
    26 #include <e32def.h>
       
    27 #include <e32base.h>
       
    28 #include <devvideoconstants.h>
       
    29 #include "aribasecodec.h"
       
    30 
       
    31 
       
    32 // FORWARD DECLARATIONS
       
    33 class MBaseCodecObserver;
       
    34 class TMpeg4H263HWDeviceInitParams;
       
    35 class TMpeg4H263EncoderInitParams;
       
    36 
       
    37 
       
    38 class CAriMp4spencWrapper:  public CBase, public MBaseCodec
       
    39 	{
       
    40 
       
    41 	public:// Constructor and Destructor
       
    42 
       
    43 		/**
       
    44 		 * Two-phased constructor.
       
    45 		 * @param aEncoderParams
       
    46 		 *    Encoder params used to create the encoder.
       
    47 		 * @return pointer to an instance of CAriMp4spencWrapper
       
    48 		 */
       
    49 		IMPORT_C static CAriMp4spencWrapper* NewL(TMpeg4H263EncoderInitParams &aParams);
       
    50 
       
    51 		/**> Destructor */
       
    52 		virtual ~CAriMp4spencWrapper();
       
    53 
       
    54 
       
    55 	public:// MBaseCodec functions
       
    56 
       
    57 		/**
       
    58 		 * From MBaseCodec
       
    59 		 * Encodes an input buffer
       
    60 		 * @param	aInpBuf
       
    61 		 *    Coded input data passed by Engine.
       
    62 		 * @param	aOutBuf
       
    63 		 *	  Encoded output data
       
    64 		 * @leave	"The method will leave if an error occurs".
       
    65 		 * @return	one of the TCodecState
       
    66 		 */
       
    67 		virtual TInt DoProcessL( TAny *aInpBuf, TAny* aOutBuf) = 0;
       
    68 
       
    69 		/**
       
    70 		 * From MBaseCodec
       
    71 		 * Encodes an input buffer
       
    72 		 * @param	aCommand
       
    73 		 *    The command passed - indicates encoder parameter to be set.
       
    74 		 * @param	aOutBuf
       
    75 		 *	  The value used to set the parameter.
       
    76 		 * @leave	"The method will leave if an error occurs".
       
    77 		 * @return	one of the TCodecState
       
    78 		 */
       
    79 
       
    80 		virtual TInt SetParam( TInt aCommand, TAny* aCmdData ) = 0;
       
    81 
       
    82 		/**
       
    83 		 * Used to get codec parameteres
       
    84 		 * @param aCommand
       
    85 		 *    Indicates the encoder parameter to get
       
    86 		 * @param aCmdData
       
    87 		 *    The value of the encoder parameter (OUT)
       
    88 		 * @return symbian wide error code
       
    89 		*/
       
    90 		virtual TInt GetParam (TInt aCommand, TAny* aCmdData) = 0;
       
    91 
       
    92 
       
    93 		/**
       
    94 		 * Cancels all processing of the commands
       
    95 		 * @return None
       
    96 		 */
       
    97 		virtual void Reset () = 0;
       
    98 
       
    99 
       
   100 		/**
       
   101 		 * Sets the clocksource.
       
   102 		 * @param aClockSource
       
   103 		 *    The clocksource which will be used by wrapper.
       
   104 		 * @param aProcessingTime
       
   105 		 *    Not used currently.
       
   106 		 * @return TInt KErrArgument if clocksource is NULL
       
   107 		 *              else returns KErrNone
       
   108 		 */
       
   109 		virtual TInt SetSyncOptions( TAny* aClockSource,
       
   110 										TInt aProcessingTime = 0 ) = 0;
       
   111 
       
   112 		/**
       
   113 		 * Sets the reference time to be used by wrapper.
       
   114 		 * @param aReferenceTime
       
   115 		 *    The reference time passed by the plugin
       
   116 		 * @return None
       
   117 		 */
       
   118 
       
   119 		virtual void SetUpdatedRefernceTime( TInt64 &aReferenceTime ) = 0;
       
   120 
       
   121 		/**
       
   122 		 * Indicates whether current picture has been encoded or not.
       
   123 		 * @return TBool ETrue if ppicture is skipped.
       
   124 		 */
       
   125 
       
   126 		virtual TBool IsCurrentPictureSkipped() = 0;
       
   127 
       
   128 	};
       
   129 
       
   130 #endif //ARIMP4SPENCWRAPPER_H