Changeset 1845


Ignore:
Timestamp:
Mar 4, 2008 4:13:01 PM (17 years ago)
Author:
bennylp
Message:

More ticket #497: bug on pjmedia_wsola_save() when extra samples exceed samples_per_frame

File:
1 edited

Legend:

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

    r1844 r1845  
    3737 
    3838/* Generate extra samples, in msec */ 
    39 #define GEN_EXTRA_PTIME (5) 
     39#define GEN_EXTRA_PTIME (1) 
    4040 
    4141/* Number of frames in erase buffer */ 
     
    513513    if (prev_lost && extra >= wsola->min_extra) { 
    514514        short *dst = wsola->buf + wsola->hist_cnt + wsola->samples_per_frame; 
     515 
     516        if (extra > wsola->samples_per_frame) 
     517            extra = wsola->samples_per_frame; 
    515518 
    516519        /* Smoothen the transition. This will also erase the excess 
Note: See TracChangeset for help on using the changeset viewer.