Ignore:
Timestamp:
Aug 1, 2009 9:20:59 AM (15 years ago)
Author:
bennylp
Message:

Initial commit for ticket #929: Improve packet lost concealment (PLC) when handling burst of lost packets

WSOLA improvements:

  • Introduce fade-out and fade-in effect
  • Limit the number of continuous synthetic samples (only take effect when fading is used)
  • Export many settings as macros:
    • PJMEDIA_WSOLA_DELAY_MSEC (was HANNING_PTIME)
    • PJMEDIA_WSOLA_TEMPLATE_LENGTH_MSEC (was TEMPLATE_PTIME)
    • PJMEDIA_WSOLA_MAX_EXPAND_MSEC

PLC:

  • added compile time macro PJMEDIA_WSOLA_PLC_NO_FADING to disable fading (default enabled)

Stream:

  • fixed bug when stream is not PLC-ing subsequent packet loss (only the first)
  • also add maximum PLC limit just as precaution if PLC doesn't limit number of synthetic frames
  • unrelated: fixed warning about unused send_keep_alive() function

Delaybuf:

  • modified to NOT use fading in WSOLA since we don't expect it to generate many continuous synthetic frames
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/src/pjmedia/plc_common.c

    r2394 r2850  
    126126{ 
    127127    struct wsola_plc *o; 
     128    unsigned flag; 
    128129    pj_status_t status; 
    129130 
     
    133134    o->prev_lost = PJ_FALSE; 
    134135 
     136    flag = PJMEDIA_WSOLA_NO_DISCARD; 
     137    if (PJMEDIA_WSOLA_PLC_NO_FADING) 
     138        flag |= PJMEDIA_WSOLA_NO_FADING; 
     139 
    135140    status = pjmedia_wsola_create(pool, clock_rate, samples_per_frame, 1, 
    136                                   PJMEDIA_WSOLA_NO_DISCARD, &o->wsola); 
     141                                  flag, &o->wsola); 
    137142    if (status != PJ_SUCCESS) 
    138143        return NULL; 
Note: See TracChangeset for help on using the changeset viewer.