[FFmpeg-devel] Patch JPEG2000 Parser: Fix parsing of tile-part header
Shaun Simpson
shauns2029 at gmail.com
Wed Jul 21 18:30:09 EEST 2021
Please find my patch attached.
libavcodec/jpeg2000_parser: Fix parsing of tile-part header, and frames
where the end of frame marker is at the end of the buffer.
Fixes playback of Sol Levante MXF JPEG2000 file:
VIDEO_e4da5fcd-5ffc-4713-bcdd-95ea579d790b.mxf
http://download.opencontent.netflix.com.s3.amazonaws.com/SolLevante/imf/SolLevante_IMF_DolbyVision_PQP3D65_UHD_24fps.zip
Bug Summary:
When playing back VIDEO_e4da5fcd-5ffc-4713-bcdd-95ea579d790b.mxf, I noticed
a regression between release 4.2.4 and release 4.3.2. Release 4.3.2 skips
some frames. This can be seen in the first 15 seconds of the video. The
Netflix logo should fade out.
This regression is in the master branch and was introduced by commit
d09c356 which adds a JPEG2000 parser. I have also tested this patch against
my 3 other JPEG2000 samples.
The patches are against master branch 13ec662 and fix playback of this file.
1. Fixed a off by one error when calculating the number of bytes to skip.
2. Added a 'continue' to the Tile part header reading, to skip the reaming
paring code during a header read.
3. To deal with the end of frame tag being at the very end of the buffer,
return the frame size during the current loop iteration.
Is the PARSER_FLAG_COMPLETE_FRAMES flag supposed to be set for the Netflix
sample? The files playback correctly if the flag is set, as each buffer
contains a complete frame, but it is not set for the test case above.
Thank you,
Shaun Simpson
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-libavcodec-jpeg2000_parser-Fix-parsing-of-tile-part-.patch
Type: text/x-patch
Size: 2941 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20210721/59991ac5/attachment.bin>
More information about the ffmpeg-devel
mailing list