mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-10 21:10:15 +00:00
(RPNG) Create adam7_restore_buf_size
This commit is contained in:
parent
1df814f9d5
commit
03984168c6
@ -457,9 +457,9 @@ static int png_reverse_filter_adam7(uint32_t *data,
|
||||
goto end;
|
||||
}
|
||||
|
||||
pngp->inflate_buf += pngp->pass.size;
|
||||
pngp->restore_buf_size += pngp->pass.size;
|
||||
pngp->stream.total_out -= pngp->pass.size;
|
||||
pngp->inflate_buf += pngp->pass.size;
|
||||
pngp->adam7_restore_buf_size += pngp->pass.size;
|
||||
pngp->stream.total_out -= pngp->pass.size;
|
||||
|
||||
png_reverse_filter_adam7_deinterlace_pass(data,
|
||||
ihdr, pngp->data, pngp->pass.width, pngp->pass.height, &passes[pngp->pass.pos]);
|
||||
@ -476,7 +476,8 @@ cont:
|
||||
return 0;
|
||||
|
||||
end:
|
||||
pngp->inflate_buf -= pngp->restore_buf_size;
|
||||
pngp->inflate_buf -= pngp->adam7_restore_buf_size;
|
||||
pngp->adam7_restore_buf_size = 0;
|
||||
|
||||
return ret;
|
||||
}
|
||||
@ -487,6 +488,9 @@ static bool png_reverse_filter_loop(struct rpng_t *rpng,
|
||||
if (rpng->ihdr.interlace == 1)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
rpng->process.adam7_restore_buf_size = 0;
|
||||
|
||||
do
|
||||
{
|
||||
ret = png_reverse_filter_adam7(*data,
|
||||
|
@ -71,6 +71,7 @@ struct rpng_process_t
|
||||
uint8_t *decoded_scanline;
|
||||
uint8_t *inflate_buf;
|
||||
size_t restore_buf_size;
|
||||
size_t adam7_restore_buf_size;
|
||||
size_t inflate_buf_size;
|
||||
unsigned bpp;
|
||||
unsigned pitch;
|
||||
|
Loading…
x
Reference in New Issue
Block a user