Ignore:
Timestamp:
Dec 15, 2011 6:45:23 AM (12 years ago)
Author:
nanang
Message:

Close #1279: Implemented custom SDP format match for G.722.1 and AMR-NB/WB.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/src/pjmedia-codec/ipp_codecs.c

    r3878 r3911  
    1919 */ 
    2020#include <pjmedia-codec/ipp_codecs.h> 
     21#include <pjmedia-codec/amr_sdp_match.h> 
     22#include <pjmedia-codec/g7221_sdp_match.h> 
    2123#include <pjmedia/codec.h> 
    2224#include <pjmedia/errno.h> 
     
    666668{ 
    667669    pjmedia_codec_mgr *codec_mgr; 
     670    pj_str_t codec_name; 
    668671    pj_status_t status; 
    669672 
     
    695698        goto on_error; 
    696699    } 
     700 
     701    /* Register format match callback. */ 
     702#if PJMEDIA_HAS_INTEL_IPP_CODEC_G722_1 
     703    pj_cstr(&codec_name, "G7221"); 
     704    status = pjmedia_sdp_neg_register_fmt_match_cb( 
     705                                        &codec_name, 
     706                                        &pjmedia_codec_g7221_match_sdp); 
     707    if (status != PJ_SUCCESS) 
     708        goto on_error; 
     709#endif 
     710 
     711#if PJMEDIA_HAS_INTEL_IPP_CODEC_AMR 
     712    pj_cstr(&codec_name, "AMR"); 
     713    status = pjmedia_sdp_neg_register_fmt_match_cb( 
     714                                        &codec_name, 
     715                                        &pjmedia_codec_amr_match_sdp); 
     716    if (status != PJ_SUCCESS) 
     717        goto on_error; 
     718#endif 
     719 
     720#if PJMEDIA_HAS_INTEL_IPP_CODEC_AMRWB 
     721    pj_cstr(&codec_name, "AMR-WB"); 
     722    status = pjmedia_sdp_neg_register_fmt_match_cb( 
     723                                        &codec_name, 
     724                                        &pjmedia_codec_amr_match_sdp); 
     725    if (status != PJ_SUCCESS) 
     726        goto on_error; 
     727#endif 
     728 
     729    /* Suppress compile warning */ 
     730    PJ_UNUSED_ARG(codec_name); 
    697731 
    698732    /* Register codec factory to endpoint. */ 
Note: See TracChangeset for help on using the changeset viewer.