Commit 5eb4701b authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/utvideodec: bswap directly without memcpy

Reviewed-by: 's avatarPaul B Mahol <onemda@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 676a589c
......@@ -187,11 +187,9 @@ static int decode_plane10(UtvideoContext *c, int plane_no,
goto fail;
}
memcpy(c->slice_bits, src + slice_data_start + c->slices * 4,
slice_size);
memset(c->slice_bits + slice_size, 0, AV_INPUT_BUFFER_PADDING_SIZE);
c->bdsp.bswap_buf((uint32_t *) c->slice_bits,
(uint32_t *) c->slice_bits,
(uint32_t *)(src + slice_data_start + c->slices * 4),
(slice_data_end - slice_data_start + 3) >> 2);
init_get_bits(&gb, c->slice_bits, slice_size * 8);
......@@ -293,11 +291,9 @@ static int decode_plane(UtvideoContext *c, int plane_no,
goto fail;
}
memcpy(c->slice_bits, src + slice_data_start + c->slices * 4,
slice_size);
memset(c->slice_bits + slice_size, 0, AV_INPUT_BUFFER_PADDING_SIZE);
c->bdsp.bswap_buf((uint32_t *) c->slice_bits,
(uint32_t *) c->slice_bits,
(uint32_t *)(src + slice_data_start + c->slices * 4),
(slice_data_end - slice_data_start + 3) >> 2);
init_get_bits(&gb, c->slice_bits, slice_size * 8);
......
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