audiostubs/devsoundextensions_stubs/inc/EAacPlusDecoderIntfcCI.h
changeset 0 0ce1b5ce9557
child 3 f935d51494d1
equal deleted inserted replaced
-1:000000000000 0:0ce1b5ce9557
       
     1 /*
       
     2 * Copyright (c) 2006-2008 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "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 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: Audio Stubs -  Custom Interface for eAAC+ decoder.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef EAACPLUSDECODERINTFCCI_H
       
    20 #define EAACPLUSDECODERINTFCCI_H
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32base.h>
       
    24 #include <EAacPlusDecoderIntfc.h>
       
    25 
       
    26 // CONSTANTS
       
    27 
       
    28 // MACROS
       
    29 
       
    30 // DATA TYPES
       
    31 
       
    32 // FUNCTION PROTOTYPES
       
    33 
       
    34 // FORWARD DECLARATIONS
       
    35 
       
    36 // CLASS DECLARATION
       
    37 
       
    38 /**
       
    39 *  Custom Interface for eAAC+ decoder.
       
    40 *
       
    41 *  @lib EAacPlusDecoderIntfcCI_Stub.lib
       
    42 *  @since S60 3.0
       
    43 */
       
    44 class CEAacPlusDecoderIntfcCI : public CEAacPlusDecoderIntfc
       
    45 	{
       
    46     public:  // Constructors and destructor
       
    47 
       
    48         /**
       
    49         * Two-phased constructor.
       
    50         */
       
    51 		IMPORT_C static CEAacPlusDecoderIntfcCI* NewL();
       
    52 
       
    53         /**
       
    54         * Destructor.
       
    55         */
       
    56         IMPORT_C virtual ~CEAacPlusDecoderIntfcCI();
       
    57 
       
    58     public: // New functions
       
    59 
       
    60     public: // Functions from CEAacPlusDecoderIntfc
       
    61 
       
    62         /**
       
    63         * Configures decoder's profile defined by TAudioObjectType.
       
    64         * @since S60 3.0
       
    65         * @param TAudioObjectType - Supported AAC profile.
       
    66         * @return void
       
    67         */
       
    68 		IMPORT_C virtual void SetAudioObjectType(
       
    69 		                      TAudioObjectType aAudioObjectType);
       
    70 
       
    71         /**
       
    72         * Configures decoder's input sampling frequency.
       
    73         * @since S60 3.0
       
    74         * @param TUint - Decoder's input sampling frequency value.
       
    75         * @return void
       
    76         */
       
    77 		IMPORT_C virtual void SetInputSamplingFrequency(
       
    78 		                      TUint aInputSamplingFrequency);
       
    79 
       
    80         /**
       
    81         * Configures the number of channels to be used by the decoder.
       
    82         * @since S60 3.0
       
    83         * @param TUint - Number of channels (stereo/mono).
       
    84         * @return void
       
    85         */
       
    86 		IMPORT_C virtual void SetNumOfChannels(TUint aNumOfChannels);
       
    87 
       
    88         /**
       
    89         * Configures decoder's spectral bandwidth replication (SBR).
       
    90         * @since S60 3.0
       
    91         * @param TBool - Toggle SBR.
       
    92         * @return void
       
    93         */
       
    94 		IMPORT_C virtual void SetSbr(TBool aSbrEnabled);
       
    95 
       
    96         /**
       
    97         * Configures decoder's down-sampled mode (DSM).
       
    98         * @since S60 3.0
       
    99         * @param TBool - Toggle DSM.
       
   100         * @return void
       
   101         */
       
   102 		IMPORT_C virtual void SetDownSampledMode(TBool aDsmEnabled);
       
   103 
       
   104         /**
       
   105         * Commits configuration settings to the decoder.
       
   106         * @since S60 3.0
       
   107         * @return TInt - Status
       
   108         */
       
   109 		IMPORT_C virtual TInt ApplyConfig();
       
   110 
       
   111         /**
       
   112         * Returns decoder's AAC profile setting.
       
   113         * @since S60 3.0
       
   114         * @param TAudioObjectType& - Reference to AAC profile.
       
   115         * @return TInt - Status
       
   116         */
       
   117 		IMPORT_C virtual TInt GetAudioObjectType(
       
   118 		                      TAudioObjectType& aAudioObjectType);
       
   119 
       
   120         /**
       
   121         * Returns decoder's input sampling frequency setting.
       
   122         * @since S60 3.0
       
   123         * @param TUint& - Reference to input sampling frequency.
       
   124         * @return TInt - Status
       
   125         */
       
   126 		IMPORT_C virtual TInt GetInputSamplingFrequency(
       
   127 		                      TUint& aInputSamplingFrequency);
       
   128 
       
   129         /**
       
   130         * Returns decoder's channel setting.
       
   131         * @since S60 3.0
       
   132         * @param TUint& - Reference to the number of channels.
       
   133         * @return TInt - Status
       
   134         */
       
   135 		IMPORT_C virtual TInt GetNumOfChannels(TUint& aNumOfChannels);
       
   136 
       
   137         /**
       
   138         * Returns decoder's SBR setting.
       
   139         * @since S60 3.0
       
   140         * @param TBool& - Reference to the SBR setting.
       
   141         * @return TInt - Status
       
   142         */
       
   143 		IMPORT_C virtual TInt GetSbr(TBool& aSbrEnabled);
       
   144 
       
   145         /**
       
   146         * Returns decoder's DSM setting.
       
   147         * @since S60 3.0
       
   148         * @param TBool& - Reference to the DSM setting.
       
   149         * @return TInt - Status
       
   150         */
       
   151 		IMPORT_C virtual TInt GetDownSampledMode(TBool& aDsmEnabled);
       
   152 
       
   153 
       
   154     protected:  // New functions
       
   155 
       
   156     protected:  // Functions from base classes
       
   157 
       
   158 	private:
       
   159 
       
   160         /**
       
   161         * C++ default constructor.
       
   162         */
       
   163 	    CEAacPlusDecoderIntfcCI();
       
   164 
       
   165         /**
       
   166         * By default Symbian 2nd phase constructor is private.
       
   167         */
       
   168 	    void ConstructL();
       
   169 
       
   170     public:     // Data
       
   171     protected:  // Data
       
   172     private:    // Data
       
   173 
       
   174         // Working config before ApplyConfig()
       
   175         TAudioObjectType  iAudioObjectType;
       
   176         TUint             iInputSamplingFrequency;
       
   177         TUint             iNumOfChannels;
       
   178         TBool             iSbrEnabled;
       
   179         TBool             iDsmEnabled;
       
   180 
       
   181         // Current config after ApplyConfig()
       
   182         TAudioObjectType  iCurrentAudioObjectType;
       
   183         TUint             iCurrentInputSamplingFrequency;
       
   184         TUint             iCurrentNumOfChannels;
       
   185         TBool             iCurrentSbrEnabled;
       
   186         TBool             iCurrentDsmEnabled;
       
   187 
       
   188 	};
       
   189 
       
   190 #endif      // EAACPLUSDECODERINTFCCI_H
       
   191 
       
   192 // End of File