mmsharing/mmshengine/inc/musenglivesession.h
changeset 22 496ad160a278
equal deleted inserted replaced
15:ccd8e69b5392 22:496ad160a278
       
     1 /*
       
     2 * Copyright (c) 2005 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 #ifndef MUSENGLIVESESSION_H
       
    20 #define MUSENGLIVESESSION_H
       
    21 
       
    22 // USER
       
    23 #include "musengmceoutsession.h"
       
    24 #include "musunittesting.h"
       
    25 #include "mussettings.h"
       
    26 #include "musengcamerahandler.h"
       
    27 
       
    28 // SYSTEM
       
    29 #include <lcvideoplayer.h>
       
    30 
       
    31 // FORWARD DECLARATIONS
       
    32 class MMusEngLiveSessionObserver;
       
    33 class CMusEngLiveVideoPlayer;
       
    34 
       
    35 
       
    36 class CMusEngLiveSession : 
       
    37     public CMusEngMceOutSession
       
    38     {
       
    39     MUS_UNITTEST( UT_CMusEngMceSession )
       
    40     MUS_UNITTEST( UT_CMusEngOutSession )
       
    41     MUS_UNITTEST( UT_CMusEngLiveSession )
       
    42     
       
    43     public:
       
    44                             
       
    45         /**
       
    46         * Creates new MultimediaSharing Live session.
       
    47         * @return CMusEngLiveSession* New instanse of specified class
       
    48         */
       
    49         static CMusEngLiveSession* NewL();
       
    50 
       
    51     public:
       
    52 
       
    53         /**
       
    54         * Destructor
       
    55         */
       
    56         ~CMusEngLiveSession();
       
    57 
       
    58     public: // from MLcSession
       
    59     
       
    60         MLcVideoPlayer* LocalVideoPlayer();  
       
    61         
       
    62     protected: // inherited from CMusEngMceOutSession
       
    63 
       
    64         /**
       
    65         * @param aLocalBundle All local streams are supposed to be added to
       
    66         *        this bundle
       
    67         */
       
    68 		void CompleteSessionStructureL( CMceStreamBundle& aLocalBundle );
       
    69 
       
    70 
       
    71     protected: // overrides ancestor class versions
       
    72                                                 
       
    73         /**
       
    74         * Sets Multimediasharing specific video codec settings like video 
       
    75         * bitrate maxbitrate. This functions gets called for every video codec 
       
    76         * in session. This function overrides function in ancestor classes. 
       
    77         * Function calls also overridden version.
       
    78         */ 
       
    79         virtual void AdjustVideoCodecL( CMceVideoCodec& aVideoCodec,
       
    80                                         TMceSourceType aSourceType );
       
    81         
       
    82         /**
       
    83         * Sets Multimediasharing specific audio codec settings. This functions 
       
    84         * gets called for every audio codec in session. This function overrides 
       
    85         * function in base class. Function calls also overridden version.
       
    86         */ 
       
    87         virtual void AdjustAudioCodecL( CMceAudioCodec& aAudioCodec );     
       
    88         
       
    89         /**
       
    90         * Removes AVC if known that it is not supported
       
    91         */
       
    92         virtual void DoCodecSelectionL( CMceVideoStream& aVideoStream );
       
    93    
       
    94 
       
    95     protected: // from MMceStreamObserver, 
       
    96              // overrides the function in CMusEngMceSession
       
    97 
       
    98         /**
       
    99         * The state of the sink has changed.
       
   100         *
       
   101         * @param aStream, the stream that uses the sink.
       
   102         * @param aSink, the sink that has changed.
       
   103         */
       
   104         void StreamStateChanged( CMceMediaStream& aStream,
       
   105                                  CMceMediaSink& aSink );    
       
   106                                  
       
   107 
       
   108     protected:
       
   109 
       
   110         /**
       
   111         * Constructor
       
   112         */
       
   113         CMusEngLiveSession();
       
   114 
       
   115         /**
       
   116         * Second-phase constructor
       
   117         */
       
   118         void ConstructL();
       
   119 
       
   120 
       
   121     protected:
       
   122         
       
   123         TMusEngCameraHandler iCameraHandler;
       
   124         CMusEngLiveVideoPlayer* iLiveVideoPlayer;
       
   125     };
       
   126 
       
   127 #endif // MUSENGLIVESESSION_H
       
   128