Ignore:
Timestamp:
Oct 24, 2011 9:28:13 AM (13 years ago)
Author:
ming
Message:

Re #1395: Backport of PJSIP 1.x branch into PJSIP 2.0 trunk

TODO: ticket #1268 (Option for automatic/manual sending of RTCP SDES/BYE for the stream) for video stream.

Location:
pjproject/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk

  • pjproject/trunk/pjmedia/src/pjmedia-codec/ipp_codecs.c

    r3664 r3841  
    4242 
    4343#define THIS_FILE   "ipp_codecs.c" 
     44 
    4445 
    4546/* Prototypes for IPP codecs factory */ 
     
    239240{ 
    240241#   if PJMEDIA_HAS_INTEL_IPP_CODEC_AMR 
    241     /* AMR-NB SID seems to produce noise, so let's just disable its VAD. */ 
    242242    {1, "AMR",      PJMEDIA_RTP_PT_AMR,       &USC_GSMAMR_Fxns,  8000, 1, 160,  
    243                     7400, 12200, 2, 0, 1,  
     243                    7400, 12200, 2, 1, 1,  
    244244                    &predecode_amr, &parse_amr, &pack_amr, 
    245245                    {1, {{{"octet-align", 11}, {"1", 1}}} } 
     
    489489        /* SID */ 
    490490        if (info->good_quality) { 
    491             pj_bool_t STI; 
    492             STI = (((pj_uint8_t*)frame.buf)[35 >> 3] & 0x10) != 0; 
    493             usc_frame->frametype = STI? 2 : 1; 
     491            usc_frame->frametype = info->STI? 2 : 1; 
    494492        } else { 
    495493            usc_frame->frametype = setting->amr_nb ? 6 : 7; 
     
    535533        info->good_quality = (pj_uint8_t)((info_ & 0x80) == 0); 
    536534        info->mode = (pj_int8_t) ((info_ >> 8) & 0x0F); 
     535        info->STI = (pj_uint8_t)((info_ >> 5) & 1); 
    537536 
    538537        frames[nframes].buf = r + 2; 
     
    14201419            /* Two octets for AMR frame info, 0=LSB: 
    14211420             * bit 0-3  : frame type 
     1421             * bit 5    : STI flag 
    14221422             * bit 6    : last frame flag 
    14231423             * bit 7    : quality flag 
     
    14431443                if (out.frametype == 6 || out.frametype == 7) 
    14441444                    *info |= 0x80; 
     1445                /* STI */ 
     1446                if (out.frametype != 1) 
     1447                    *info |= 0x20; 
    14451448            } else { 
    14461449                /* Untransmited */ 
Note: See TracChangeset for help on using the changeset viewer.