mmserv/voipaudioservices/VoIPIntfc/src/VoIPDownlinkStream.cpp
changeset 0 71ca22bcf22a
equal deleted inserted replaced
-1:000000000000 0:71ca22bcf22a
       
     1 /*
       
     2  * Copyright (c) 2007-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:  Downlink stream APIs.
       
    15  *
       
    16  */
       
    17 
       
    18 #include <voipdatabuffer.h>
       
    19 #include <voipdownlinkstream.h>
       
    20 #include "VoIPDownlinkStreamImpl.h"
       
    21 
       
    22 // ---------------------------------------------------------------------------
       
    23 // CVoIPAudioDownlinkStream::~CVoIPAudioDownlinkStream
       
    24 // ---------------------------------------------------------------------------
       
    25 //
       
    26 EXPORT_C CVoIPAudioDownlinkStream::~CVoIPAudioDownlinkStream()
       
    27     {
       
    28     }
       
    29 
       
    30 // ---------------------------------------------------------------------------
       
    31 // CVoIPAudioDownlinkStream::CVoIPAudioDownlinkStream
       
    32 // ---------------------------------------------------------------------------
       
    33 //
       
    34 CVoIPAudioDownlinkStream::CVoIPAudioDownlinkStream()
       
    35     {
       
    36     }
       
    37 
       
    38 // ---------------------------------------------------------------------------
       
    39 // CVoIPAudioDownlinkStream::ConstructL
       
    40 // ---------------------------------------------------------------------------
       
    41 //
       
    42 void CVoIPAudioDownlinkStream::ConstructL(
       
    43         CVoIPAudioDownlinkStreamImpl* aVoIPAudioDownlinkStreamImpl)
       
    44     {
       
    45     iVoIPAudioDownlinkStreamImpl = aVoIPAudioDownlinkStreamImpl;
       
    46     }
       
    47 
       
    48 // ---------------------------------------------------------------------------
       
    49 // CVoIPAudioDownlinkStream::Open
       
    50 // ---------------------------------------------------------------------------
       
    51 //
       
    52 EXPORT_C TInt CVoIPAudioDownlinkStream::Open(MVoIPDownlinkObserver& aObserver)
       
    53     {
       
    54     TInt err = iVoIPAudioDownlinkStreamImpl->Open(aObserver);
       
    55     return err;
       
    56     }
       
    57 
       
    58 // ---------------------------------------------------------------------------
       
    59 // CVoIPAudioDownlinkStream::GetVersion
       
    60 // ---------------------------------------------------------------------------
       
    61 //
       
    62 EXPORT_C TInt CVoIPAudioDownlinkStream::GetVersion(TVersion& aVersion)
       
    63     {
       
    64     TInt err = iVoIPAudioDownlinkStreamImpl->GetVersion(aVersion);
       
    65     return err;
       
    66     }
       
    67 
       
    68 // ---------------------------------------------------------------------------
       
    69 // CVoIPAudioDownlinkStream::GetMaxVolume
       
    70 // ---------------------------------------------------------------------------
       
    71 //
       
    72 EXPORT_C TInt CVoIPAudioDownlinkStream::GetMaxVolume(TInt& aVolume)
       
    73     {
       
    74     TInt err = iVoIPAudioDownlinkStreamImpl->GetMaxVolume(aVolume);
       
    75     return err;
       
    76     }
       
    77 
       
    78 // ---------------------------------------------------------------------------
       
    79 // CVoIPAudioDownlinkStream::SetVolume
       
    80 // ---------------------------------------------------------------------------
       
    81 //
       
    82 EXPORT_C TInt CVoIPAudioDownlinkStream::SetVolume(TInt aVolume)
       
    83     {
       
    84     TInt err = iVoIPAudioDownlinkStreamImpl->SetVolume(aVolume);
       
    85     return err;
       
    86     }
       
    87 
       
    88 // ---------------------------------------------------------------------------
       
    89 // CVoIPAudioDownlinkStream::GetVolume
       
    90 // ---------------------------------------------------------------------------
       
    91 //
       
    92 EXPORT_C TInt CVoIPAudioDownlinkStream::GetVolume(TInt& aVolume)
       
    93     {
       
    94     TInt err = iVoIPAudioDownlinkStreamImpl->GetVolume(aVolume);
       
    95     return err;
       
    96     }
       
    97 
       
    98 // ---------------------------------------------------------------------------
       
    99 // CVoIPAudioDownlinkStream::SetFormat
       
   100 // ---------------------------------------------------------------------------
       
   101 //
       
   102 EXPORT_C TInt CVoIPAudioDownlinkStream::SetFormat(TVoIPCodecFormat aFormat,
       
   103         CVoIPFormatIntfc*& aIntfc)
       
   104     {
       
   105     TRAPD(err, iVoIPAudioDownlinkStreamImpl->SetFormatL(aFormat, aIntfc));
       
   106     return err;
       
   107     }
       
   108 
       
   109 // ---------------------------------------------------------------------------
       
   110 // CVoIPAudioDownlinkStream::SetAudioDevice
       
   111 // ---------------------------------------------------------------------------
       
   112 //
       
   113 EXPORT_C TInt CVoIPAudioDownlinkStream::SetAudioDevice(
       
   114         TVoIPOutputDevice aDevice)
       
   115     {
       
   116     TInt err = iVoIPAudioDownlinkStreamImpl->SetAudioDevice(aDevice);
       
   117     return err;
       
   118     }
       
   119 
       
   120 // ---------------------------------------------------------------------------
       
   121 // CVoIPAudioDownlinkStream::GetAudioDevice
       
   122 // ---------------------------------------------------------------------------
       
   123 //
       
   124 EXPORT_C TInt CVoIPAudioDownlinkStream::GetAudioDevice(
       
   125         TVoIPOutputDevice& aDevice)
       
   126     {
       
   127     TInt err = iVoIPAudioDownlinkStreamImpl->GetAudioDevice(aDevice);
       
   128     return err;
       
   129     }
       
   130 
       
   131 // ---------------------------------------------------------------------------
       
   132 // CVoIPAudioDownlinkStream::Start
       
   133 // ---------------------------------------------------------------------------
       
   134 //
       
   135 EXPORT_C TInt CVoIPAudioDownlinkStream::Start()
       
   136     {
       
   137     TInt err = iVoIPAudioDownlinkStreamImpl->Start();
       
   138     return err;
       
   139     }
       
   140 
       
   141 // ---------------------------------------------------------------------------
       
   142 // CVoIPAudioDownlinkStream::Stop
       
   143 // ---------------------------------------------------------------------------
       
   144 //
       
   145 EXPORT_C TInt CVoIPAudioDownlinkStream::Stop()
       
   146     {
       
   147     TInt err = iVoIPAudioDownlinkStreamImpl->Stop();
       
   148     return err;
       
   149     }
       
   150 
       
   151 // ---------------------------------------------------------------------------
       
   152 // CVoIPAudioDownlinkStream::Close
       
   153 // ---------------------------------------------------------------------------
       
   154 //
       
   155 EXPORT_C void CVoIPAudioDownlinkStream::Close()
       
   156     {
       
   157     iVoIPAudioDownlinkStreamImpl->Close();
       
   158     }
       
   159 
       
   160 // ---------------------------------------------------------------------------
       
   161 // CVoIPAudioDownlinkStream::BufferFilled
       
   162 // ---------------------------------------------------------------------------
       
   163 //
       
   164 EXPORT_C TInt CVoIPAudioDownlinkStream::BufferFilled(CVoIPDataBuffer* aBuffer)
       
   165     {
       
   166     TInt err = iVoIPAudioDownlinkStreamImpl->BufferFilled(aBuffer);
       
   167     return err;
       
   168     }
       
   169 
       
   170 // End of file