Changeset 3229

Show
Ignore:
Timestamp:
03/02/00 08:32:52 (14 years ago)
Author:
ucacoxh
Message:

- Add back audio_scale_buffer. Got edited out yestereday when playing

with something else altogether.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • rat/trunk/audio_util.c

    r3228 r3229  
    240240        return (uint16_t)(e1*ENERGY_CALC_STEP/samples); 
    241241} 
     242 
     243void 
     244audio_scale_buffer(sample *buf, int len, double scale) 
     245{ 
     246        int i; 
     247        for(i = 0; i < len; i++) { 
     248                buf[i] = (sample)((double)buf[i] * scale); 
     249        } 
     250}