mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-04-14 00:58:38 +02:00
sgidec: use bytestream2_get_bufferu()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
fcaf5fa2ea
commit
f12c27daf7
@ -138,9 +138,10 @@ static int read_uncompressed_sgi(unsigned char* out_buf, SgiState *s)
|
|||||||
for (y = s->height - 1; y >= 0; y--) {
|
for (y = s->height - 1; y >= 0; y--) {
|
||||||
out_end = out_buf + (y * s->linesize);
|
out_end = out_buf + (y * s->linesize);
|
||||||
if (s->bytes_per_channel == 1) {
|
if (s->bytes_per_channel == 1) {
|
||||||
for (x = s->width; x > 0; x--)
|
for (x = s->width; x > 0; x--) {
|
||||||
for (z = 0; z < s->depth; z++)
|
bytestream2_get_bufferu(&gp[z], out_end, s->depth);
|
||||||
*out_end++ = bytestream2_get_byteu(&gp[z]);
|
out_end += s->depth;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
uint16_t *out16 = (uint16_t *)out_end;
|
uint16_t *out16 = (uint16_t *)out_end;
|
||||||
for (x = s->width; x > 0; x--)
|
for (x = s->width; x > 0; x--)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user