multimediacommscontroller/mmccsubcontroller/inc/mccsymsimpledlstream.h
changeset 0 1bce908db942
child 32 f2ed1fc4c163
equal deleted inserted replaced
-1:000000000000 0:1bce908db942
       
     1 /*
       
     2 * Copyright (c) 2006 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:    
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef MCCSYMSIMPLEDLSTREAM_H
       
    21 #define MCCSYMSIMPLEDLSTREAM_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include "mccsymstreambase.h"
       
    25 #include "mccrtpdatasource.h"
       
    26 #include "mccjitterbufferobserver.h"
       
    27 
       
    28 // FORWARD DECLARATIONS
       
    29 class CMMFFormatDecode;
       
    30 class MMccResources;
       
    31 
       
    32 // CLASS DECLARATION
       
    33 
       
    34 /**
       
    35 *  MCP Symmetric subthread simple downlink stream
       
    36 *
       
    37 *  @lib Mccsubthreads.lib
       
    38 *  @since Series 60 3.0
       
    39 */
       
    40 NONSHARABLE_CLASS( CMccSymSimpleDlStream ) : public CMccSymStreamBase, public MJitterBufferObserver
       
    41     {
       
    42     public:  // Constructors and destructor
       
    43         
       
    44         /**
       
    45         * Static constructor
       
    46         */
       
    47         static CMccSymSimpleDlStream* NewLC( TUint32 aMccStreamId, 
       
    48                                              MAsyncEventHandler* aEventhandler,  
       
    49                                              MMccResources* aMccResources,
       
    50                                              CMccRtpManager* aManager, 
       
    51                                              TFourCC aFourCC, 
       
    52                                              TInt aStreamType );
       
    53         
       
    54         /**
       
    55         * Destructor.
       
    56         */
       
    57         virtual ~CMccSymSimpleDlStream();
       
    58 
       
    59     public: // New functions
       
    60 
       
    61 		void CreatePayloadFormatDecoderL();
       
    62 
       
    63     public: // Functions from base classes
       
    64     
       
    65         /**
       
    66         * From CMccSymStreamBase
       
    67         */
       
    68         void SetPrioritySettingsL( const TMMFPrioritySettings& aPriority );
       
    69         
       
    70         /**
       
    71         * From CMccSymStreamBase
       
    72         */
       
    73         void AddSinkAndSourceL( MDataSink* aDatasink, 
       
    74                 MDataSource* aDatasource );
       
    75         
       
    76         /**
       
    77         * From CMccSymStreamBase
       
    78         */      
       
    79         void LoadCodecL( const TMccCodecInfo& aCodecInfo,
       
    80                          const TDesC8& aFmtp );
       
    81         
       
    82         void UpdateCodecInformationL( TMccCodecInfo& aCodecInfo );
       
    83 
       
    84         /**
       
    85         * From CMccSymStreamBase
       
    86         */
       
    87         void PrimeL( const TUint32 aEndpointId );
       
    88         
       
    89         /**
       
    90         * From CMccSymStreamBase
       
    91         */
       
    92         void PlayL( const TUint32 aEndpointId,
       
    93         			TBool aStreamPaused, 
       
    94                     TBool aEnableRtcp );
       
    95         
       
    96         /**
       
    97         * From CMccSymStreamBase
       
    98         */
       
    99         void PauseL( const TUint32 aEndpointId,
       
   100         			 TBool aEnableRtcp );
       
   101         
       
   102         /**
       
   103         * From CMccSymStreamBase
       
   104         */
       
   105         void ResumeL( const TUint32 aEndpointId,
       
   106         			  TBool aEnableRtcp );
       
   107         
       
   108         /**
       
   109         * From CMccSymStreamBase
       
   110         */
       
   111         void StopL( const TUint32 aEndpointId );
       
   112 
       
   113         /**
       
   114         * From CMccSymStreamBase
       
   115         */
       
   116         void SetBalanceL( TInt aLeftbal, TInt aRightbal );
       
   117         
       
   118         /**
       
   119         * From CMccSymStreamBase
       
   120         */
       
   121         void GetBalanceL( TInt& aLeftbal, TInt& aRightbal );
       
   122         
       
   123         /**
       
   124         * From CMccSymStreamBase
       
   125         */ 
       
   126         void GetSSRCL( TUint32& aSSRCValue );
       
   127         
       
   128         /**
       
   129         * From CMccSymStreamBase
       
   130         */
       
   131         void ResetCountersL();
       
   132         
       
   133         /**
       
   134         * From CMccSymStreamBase
       
   135         */
       
   136         void SendMediaSignalL( const TMccEvent& aEvent );
       
   137         
       
   138         /**
       
   139         * Sends RTCP receiver report.
       
   140         * @param none
       
   141         * @return One of the standard system-wide error codes.
       
   142         */
       
   143         void SendRTCPReceiverReportL();
       
   144         
       
   145         /** 
       
   146         * Starts inactivity timer for a stream
       
   147         * @param aTimeoutTime - [input] timeout value in milliseconds
       
   148         * @return One of the standard system-wide error codes.
       
   149         */
       
   150         void StartInactivityTimerL( TUint32 aTimeoutTime );
       
   151 
       
   152         /**
       
   153         * Stops inactivity timer for a stream 
       
   154         * @return One of the standard system-wide error codes.
       
   155         */
       
   156         void StopInactivityTimerL();
       
   157         
       
   158         /**
       
   159         * Checks if stream is uplink 
       
   160         * @return EFalse for downlink stream.
       
   161         */
       
   162         TBool IsUplink();
       
   163 
       
   164         /**
       
   165         * Sets stream to standby mode. 
       
   166         */
       
   167         void StandByL();
       
   168         
       
   169         /**
       
   170          * From MJitterBufferObserver
       
   171          */
       
   172         void JitterBufferError( TInt aError );
       
   173         
       
   174         /**
       
   175          * From MJitterBufferObserver
       
   176          */
       
   177         void DynamicBufferChangeRequest( TInt aBufferSize );
       
   178 
       
   179     private:
       
   180         
       
   181         /**
       
   182         * C++ default constructor.
       
   183         */
       
   184         CMccSymSimpleDlStream( TUint32 aMccStreamId, 
       
   185                                MAsyncEventHandler* aEventhandler, 
       
   186                                MMccResources* aMccResources,
       
   187                                CMccRtpManager* aManager, 
       
   188                                TFourCC aFourCC, 
       
   189                                TInt aStreamType );
       
   190         
       
   191         /**
       
   192         * 2nd phase constructor
       
   193         */
       
   194         void ConstructL();
       
   195 
       
   196             
       
   197     protected: // Functions from base classes
       
   198     
       
   199         MDataSink* MultiplexerSink();
       
   200         
       
   201     private:    // Data
       
   202     
       
   203     	TFourCC iFourCC;
       
   204     
       
   205         CMMFFormatDecode* iFormatDecode;
       
   206     private: // friend class
       
   207         #ifdef TEST_EUNIT
       
   208         friend class UT_CMccSymSimpleDlStream;
       
   209         #endif
       
   210     };
       
   211 
       
   212 #endif      // MCCSYMSIMPLEDLSTREAM_H
       
   213 
       
   214 // End of File