Changeset 3035

Show
Ignore:
Timestamp:
01/05/00 13:58:22 (14 years ago)
Author:
ucacoxh
Message:

- Added fix for stereo channels in find_local_match.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • rat/trunk/source.c

    r3034 r3035  
    957957 
    958958        if (score_min / wlen < MATCH_THRESHOLD) { 
    959                 return i_min; 
     959                return i_min / channels; 
    960960        } 
    961961        return -1; 
     
    10121012                matchlen = samples - matchlen - SOURCE_COMPARE_WINDOW_SIZE; 
    10131013        } 
    1014  
     1014        assert(matchlen >= 0); 
     1015        assert(matchlen <= samples); 
    10151016        *adjust = ts_map32(rate, matchlen); 
    10161017        return TRUE;