diff options
author | Alex Converse <alex.converse@gmail.com> | 2011-09-27 10:24:28 -0700 |
---|---|---|
committer | Alex Converse <alex.converse@gmail.com> | 2011-09-28 12:33:51 -0700 |
commit | daf98908118074e96199ca7195663af4543d3808 (patch) | |
tree | 7e82935537bbfa12ca18b0499583e48962872f80 /avconv.c | |
parent | baf6b738f23bbe7db3a8438372d01a958492e477 (diff) | |
download | ffmpeg-daf98908118074e96199ca7195663af4543d3808.tar.gz |
avconv: Reformat s16 volume adjustment.
Diffstat (limited to 'avconv.c')
-rw-r--r-- | avconv.c | 13 |
1 files changed, 6 insertions, 7 deletions
@@ -1676,13 +1676,12 @@ static int output_packet(InputStream *ist, int ist_index, } case AV_SAMPLE_FMT_S16: { - short *volp; - volp = samples; - for(i=0;i<(decoded_data_size / sizeof(short));i++) { - int v = ((*volp) * audio_volume + 128) >> 8; - *volp++ = av_clip_int16(v); - } - break; + int16_t *volp = samples; + for (i = 0; i < (decoded_data_size / sizeof(*volp)); i++) { + int v = ((*volp) * audio_volume + 128) >> 8; + *volp++ = av_clip_int16(v); + } + break; } case AV_SAMPLE_FMT_S32: { |