Changes between Version 12 and Version 13 of Nokia_APS_VAS_Direct


Ignore:
Timestamp:
Feb 16, 2009 3:30:08 PM (11 years ago)
Author:
bennylp
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Nokia_APS_VAS_Direct

    v12 v13  
    33 
    44'''Table of Contents''' 
    5 [[PageOutline(1-3,,inline)]] 
     5[[PageOutline(2-3,,inline)]] 
    66 
    77 
     
    1313[[BR]] 
    1414 
    15 = Introduction = 
     15== Introduction == 
    1616 
    1717The Nokia APS and VAS support codecs such as G.711 (PCMA and PCMU), G.729, iLBC, and AMR-NB, though the availability of these codecs may vary according to the handset types. There are significant benefits of using these codecs instead of software codecs (in PJMEDIA-CODEC), with the main benefits are performance (hardware vs software codecs, latency) and the given codec licenses/royalties. 
     
    2323[[BR]] 
    2424 
    25 = Concepts = 
     25== Concepts == 
    2626 
    2727Before starting working with APS-Direct, please make sure you understand the concepts behind APS-Direct so that you can design the application appropriately. 
     
    2929The whole point of APS-Direct is to enable end-to-end '''encoded audio format media flow''', that is from microphone device down to network/socket and from network/socket to the speaker device. This may sound obvious, but it has the following serious implications which will impact your application design. 
    3030 
    31 == What APS-Direct is really == 
     31=== What APS-Direct is really === 
    3232 
    3333To use APS-Direct means that you're opening the sound device in codec (i.e. non-PCM) mode. You '''still have the choice''', at run-time, to open the sound device in PCM mode, if you wish, for example to make use of the PCM features in PJMEDIA such as the tone generator, or if you want to use the software codecs such as Speex or G.722 in PJMEDIA. Note that if you use PJSUA-LIB then the management of closing/re-opening the sound device using the correct codec may be done by PJSUA-LIB automatically. 
    3434 
    35 To use APS-Direct also means that you are restricted to use the audio switchboard at compile time (audio switchboard will be explained later). This means that you loose the capability of mixing audio with PJSUA-LIB, as well as several other restrictions on your audio routing arrangements. Among other things, you can't have two calls active and connected to the audio device at the same time. You can have more than one calls, but one of them must be put on-hold. 
    36  
    37 The sound device can only handle one format at a time, meaning that if it is currently opened with G.729 format (for one call for example), you can't feed it with PCM frames for example from the tone generator or PCM WAV files. All PJMEDIA features that work with PCM audio will no longer work if the audio device is currently opened in codec mode. This includes the tone generator (tonegen) and WAV files. If you wish to use any of the features above, you must close the sound device and re-open it in PCM mode. 
    38  
    39  
    40 == When APS-Direct is activated == 
     35To use APS-Direct also means that you are restricted to use the ''audio switchboard'' at compile time (audio switchboard will be explained later). This means that you loose the capability of mixing audio with PJSUA-LIB, as well as several other restrictions on your audio routing arrangements. Among other things, you can't have two calls active and connected to the audio device at the same time. You can have more than one calls, but one of them must be put on-hold. 
     36 
     37The sound device can only handle one format at a time. For example, if it is currently opened with G.729 format, you can't reconnect it to different media ports (such as stream or other pjmedia_port). You must first close it, then re-open it using the correct format. 
     38 
     39 
     40=== When APS-Direct is activated === 
    4141 
    4242APS-Direct is used when passthrough codec is used (and vice versa): 
    43  - when APS-Direct is used, the sound device emits and takes encoded audio frames (in contrast to PCM audio frames), and the stream needs special codec which handles this. This special codec is called passthrough codec, since it just do (de)packetization and not the actual encoding/decoding. 
     43 - when APS-Direct is used, the sound device emits and takes encoded audio frames (as opposed to PCM audio frames), and the stream needs special codec which handles this. This special codec is called passthrough codec, since it just do (de)packetization and not the actual encoding/decoding. 
    4444 - similarly when passthrough codec is selected in the stream, the stream will emit and take encoded audio frames (rather than PCM frames), hence it needs APS-Direct on the other side. 
    4545 
    46 One important thing to note: '''you may still use software codecs such as Speex and G.722 even when your application is compiled with APS-Direct support'''. When one of these software codecs are selected to be used by the stream, the stream will work as usual (i.e. emitting and taking PCM audio frames) and the audio device should be opened in normal/PCM mode (i.e. non-APS-Direct mode). 
    47  
    48  
    49 [[BR]] 
    50  
    51 = Changes = 
     46One important thing to note: '''you may still use software codecs such as Speex and G.722 even when your application is compiled with APS-Direct support'''. When one of these software codecs is selected to be used by the stream, the stream will work as usual (i.e. emitting and taking PCM audio frames), so the audio device '''must''' be opened in normal/PCM mode (i.e. non-APS-Direct mode). 
     47 
     48 
     49[[BR]] 
     50 
     51== Changes == 
    5252 
    5353The use of APS-Direct and VAS-Direct is very different than traditional PJMEDIA media processing, with the main difference being the audio frames returned by/given to the sound device are now in encoded format rather than in raw PCM format. The following changes will be done in order to support this. 
    5454 
    5555 
    56 == Support for non-PCM format == 
     56=== Support for non-PCM format === 
    5757 
    5858 
     
    9393The stream must also support non-PCM audio frames in its {{{get_frame()}}} and {{{put_frame()}}} port interface.  
    9494 
    95 == Passthrough Codecs == 
     95=== Passthrough Codecs === 
    9696 
    9797While the actual codec encoding/decoding will be done by APS/VAS, "dummy" codec instances still need to be created in PJMEDIA: 
     
    102102 
    103103 
    104 == (Symbian) Sound Device API == 
     104=== (Symbian) Sound Device API === 
    105105 
    106106The APS/VAS based sound device backends will support additional APIs: 
     
    110110 
    111111 
    112 == New Audio Switchboard (the non-mixing conference bridge) == 
     112=== New Audio Switchboard (the non-mixing conference bridge) === 
    113113 
    114114Since audio frames are forwarded back and forth in encoded format, obviously the traditional conference bridge would not be able to handle it. A new object will be added, we call this audio switchboard ({{{conf_switch.c}}}) and it's API will be compatible with the existing conference bridge API, so that it can replace the bridge in the application by compile time switch. 
     
    132132[[BR]] 
    133133 
    134 = Using APS-Direct or VAS-Direct = 
     134== Using APS-Direct or VAS-Direct == 
    135135 
    136136Currently only APS-Direct is implemented, and here are the steps to build the application with APS- Direct feature. 
     
    231231 
    232232 
    233 = References = 
     233== References == 
    234234 
    235235Internal documentations: