Commit 09905c41 authored by Kevin Wheatley's avatar Kevin Wheatley Committed by Paul B Mahol

libavcodec/exr: Fix blank output when data window != display window

looks like there is a bug in commit
1a08758e relating to the handling of
ptr in decode_frame after decode_block is called, before this commit
ptr would have been incremented for each line in the data window, now
after the commit it is left at the start of the first included line
rather than the line after the data window then the code sets the
remaining lines to 0 and thus the whole image is over written.

Fix by adjusting ptr to the correct line after decode_block returns
Signed-off-by: 's avatarKevin Wheatley <kevin.j.wheatley@gmail.com>
parent bc6b53ae
......@@ -1729,6 +1729,7 @@ static int decode_frame(AVCodecContext *avctx, void *data,
avctx->execute2(avctx, decode_block, s->thread_data, NULL, nb_blocks);
// Zero out the end if ymax+1 is not h
ptr = picture->data[0] + ((s->ymax+1) * picture->linesize[0]);
for (y = s->ymax + 1; y < avctx->height; y++) {
memset(ptr, 0, out_line_size);
ptr += picture->linesize[0];
......
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