Commit 4c4ebeb5 authored by James Almer's avatar James Almer

avcodec/wavpackenc: use put_sbits

Reviewed-by: 's avatarPaul B Mahol <onemda@gmail.com>
Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent 4a3cf186
......@@ -2216,8 +2216,7 @@ static void pack_float_sample(WavPackEncodeContext *s, int32_t *sample)
}
} else if (shift_count) {
if (s->float_flags & FLOAT_SHIFT_SENT) {
int32_t data = get_mantissa(*sample) & ((1 << shift_count) - 1);
put_bits(pb, shift_count, data);
put_sbits(pb, shift_count, get_mantissa(*sample));
} else if (s->float_flags & FLOAT_SHIFT_SAME) {
put_bits(pb, 1, get_mantissa(*sample) & 1);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment