Symbian3/PDK/Source/GUID-9DC82237-3A81-53C8-97A7-8ACA5C97A5EC.dita
changeset 1 25a17d01db0c
child 3 46218c8b8afa
equal deleted inserted replaced
0:89d6a7a84779 1:25a17d01db0c
       
     1 <?xml version="1.0" encoding="utf-8"?>
       
     2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
       
     3 <!-- This component and the accompanying materials are made available under the terms of the License 
       
     4 "Eclipse Public License v1.0" which accompanies this distribution, 
       
     5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
       
     6 <!-- Initial Contributors:
       
     7     Nokia Corporation - initial contribution.
       
     8 Contributors: 
       
     9 -->
       
    10 <!DOCTYPE concept
       
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
       
    12 <concept id="GUID-9DC82237-3A81-53C8-97A7-8ACA5C97A5EC" xml:lang="en"><title>Overview</title><prolog><metadata><keywords/></metadata></prolog><conbody>
       
    13 <section><title>Purpose</title> <p>The AMR payload formatter provides APIs
       
    14 to pack and unpack AMR encoded data as per <xref href="http://www.faqs.org/rfcs/rfc3267.html" scope="external">RFC 3267</xref>, giving common APIs for future formatter
       
    15 implementations. This overview shows the usage of APIs included in the AMR
       
    16 payload formatter component. This component is implemented as an ECOM plug-in
       
    17 and has a common interface that can be used by other formatter implementations
       
    18 for codecs like MPEG. </p> </section>
       
    19 <section><title>Required background</title> <p>It is assumed the user has
       
    20 an understanding of the AMR codec, IF1 and IF2 header formats. The user must
       
    21 know the valid AMR stream property values and bit rates supported for AMR
       
    22 wide and narrow band respectively. </p> </section>
       
    23 <section><title>Key concepts</title> <dl>
       
    24 <dlentry>
       
    25 <dt>Adaptive Multi-Rate (AMR)</dt>
       
    26 <dd><p>The AMR codec is a multi-mode codec that supports 8 narrow band speech
       
    27 encoding modes with bit rates between 4.75 kbps and 12.2 kbps. The sampling
       
    28 frequency used in AMR is 8000 Hz and the speech encoding is performed
       
    29 on 20 ms speech frames. So, each encoded AMR speech frame represents 160 samples
       
    30 of the original speech. </p> </dd>
       
    31 </dlentry>
       
    32 </dl> <dl>
       
    33 <dlentry>
       
    34 <dt>Codec</dt>
       
    35 <dd><p>A codec is a device or a program capable of encoding and decoding a
       
    36 digital data stream or signal. </p> </dd>
       
    37 </dlentry>
       
    38 </dl> </section>
       
    39 <section><title>API summary </title> <table id="GUID-14F0C0C3-7D1C-5054-95EA-3BB783A1D117">
       
    40 <tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
       
    41 <thead>
       
    42 <row>
       
    43 <entry>Class Name</entry>
       
    44 <entry>Description</entry>
       
    45 </row>
       
    46 </thead>
       
    47 <tbody>
       
    48 <row>
       
    49 <entry><p> <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-F885E957-C375-3CF9-82B7-2611B0974675"><apiname>CStreamFormatter::Pack()</apiname></xref>  </p> </entry>
       
    50 <entry><p>An API that is used to pack the encoded AMR data. </p> </entry>
       
    51 </row>
       
    52 <row>
       
    53 <entry><p> <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-B2F9AE75-87B9-3331-91DA-8FDA72E317F2"><apiname>CStreamFormatter::Unpack()</apiname></xref>  </p> </entry>
       
    54 <entry><p>An API that is used to extract the AMR payload header from the data
       
    55 and gives it back to the application. </p> </entry>
       
    56 </row>
       
    57 <row>
       
    58 <entry><p> <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-801B3E2A-2B63-35A9-A871-7519D4869326"><apiname>CStreamFormatter::SetStreamProperty()</apiname></xref>  </p> </entry>
       
    59 <entry><p>An API that is used to set the identified AMR stream properties
       
    60 if the session has already started. </p> </entry>
       
    61 </row>
       
    62 <row>
       
    63 <entry><p> <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-447345B5-1F60-3273-A320-B313D388748B"><apiname>CStreamFormatter::GetStreamProperty()</apiname></xref>  </p> </entry>
       
    64 <entry><p>An API that is used to get the current AMR stream properties for
       
    65 the session in progress. </p> </entry>
       
    66 </row>
       
    67 </tbody>
       
    68 </tgroup>
       
    69 </table> </section>
       
    70 <section><title>Typical uses</title> <p>An application using the AMR plug-in
       
    71 component must include <filepath>streamformatter.h</filepath>, <filepath>amrproperty.h</filepath>, <filepath>ecom.h</filepath> and<filepath> ECOM.lib</filepath> files, and it uses the DLL that is provided to write the application code.
       
    72 Here we support both AMR narrow band and AMR wide band. </p> <p>The user has
       
    73 a choice to either use the AMR payload formatter or provide the UID of the
       
    74 implementation that the user wants to use in the <codeph>CStreamFormatter::NewL()</codeph> function.
       
    75 This function is overloaded, that is, it takes as default the AMR payload
       
    76 formatter or any formatter the user has. </p> <p><b>Creating the interface</b> </p> <p>A
       
    77 user must first create the interface to use the AMR payload formatter. For
       
    78 more information on creating the interface see, <xref href="GUID-F5D2C8DF-58B5-5620-824B-86BE72341DF7.dita">How
       
    79 to Create the Interface</xref>. </p> <p><b>Packing and unpacking the AMR encoded
       
    80 data</b> </p> <p>The application user uses the <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-F885E957-C375-3CF9-82B7-2611B0974675"><apiname>CStreamFormatter::Pack()</apiname></xref> and <xref href="GUID-2283C5F3-9237-38BE-933C-353ADF676B42.dita#GUID-2283C5F3-9237-38BE-933C-353ADF676B42/GUID-B2F9AE75-87B9-3331-91DA-8FDA72E317F2"><apiname>CStreamFormatter::Unpack()</apiname></xref> APIs
       
    81 to pack and unpack the AMR encoded data. For more information on packing and
       
    82 unpacking the AMR encoded data see, <xref href="GUID-42665F58-7E04-5375-A039-7BBDE218DDE4.dita">How
       
    83 to Pack and Unpack the AMR Encoded Data</xref>. </p> <p><b>Setting and getting
       
    84 the AMR stream property</b> </p> <p>A user has an option to set and get the
       
    85 AMR stream properties if the user wants to change any of the AMR stream properties.
       
    86 If a user does not want to change any of the AMR stream properties then it
       
    87 takes the default values assigned to the respective properties. </p> <p>For
       
    88 more information see, <xref href="GUID-CCFFFE06-1FB8-56C8-874C-C4C1B936FAA4.dita">How
       
    89 to Set and Get the AMR Stream Property</xref>. </p> </section>
       
    90 </conbody></concept>