[FFmpeg-devel] [PATCH v4 0/4] JPEG XL Parser
Leo Izen
leo.izen at gmail.com
Mon Jun 26 18:49:18 EEST 2023
Changes from v3:
- Don't remove AV_CODEC_CAP_DR1 from libjxldec
- jpegxl_parse.o added to STLIBOBJS in avcodec/Makefile
- add pipe demuxer to avformat/Makefile's SHLIBOBJS
Changes from v2:
- Fix libjxldec to work with packets that are smaller than one frame
- Change how code is shared between libavcodec and libavformat to be more sensible.
- Fix the parser to work with large headers that proceed the codestream in a container format
(for example, if several-KB Exif boxes preceed the codestream.)
- Modify the parser to set width/height instead of avctx
Note: avctx->pix_fmt and s->format are both set, because otherwise the CLI tools won't print
the pixel format without libjxl enabled.
- Update the fate test based on the new parser's packetization
This test relies on FATE samples that haven't been uploaded yet. To test, unzip
the following zipfile[1] in the FATE_SAMPLES directory, placing the test images in jxl/.
[1]: https://buzo.us/y.zip
sha256sum: 43a2eeb0dfdf471b47a9fdfb1653974fa156ceceb776891cc137569a8ebf0e75
signature: https://buzo.us/R.asc
Leo Izen (4):
avcodec/libjxldec: use internal AVFrame as buffered space
avcodec/jpegxl_parser: add JPEG XL parser
avformat/jpegxl: remove jpegxl_probe, instead call
avcodec/jpegxl_parse
fate/jpegxl_anim: add demuxer fate test for jpegxl_anim
libavcodec/Makefile | 3 +
libavcodec/jpegxl.h | 72 ++++++
.../jpegxl_parse.c | 219 ++++++++++++------
libavcodec/jpegxl_parse.h | 63 +++++
libavcodec/jpegxl_parser.c | 182 +++++++++++++++
libavcodec/libjxldec.c | 38 +--
libavcodec/parsers.c | 1 +
libavcodec/version.h | 2 +-
libavformat/Makefile | 6 +-
libavformat/img2dec.c | 4 +-
libavformat/jpegxl_anim_dec.c | 114 ++-------
.../{jpegxl_probe.h => jpegxl_parse.c} | 21 +-
tests/Makefile | 1 +
tests/fate/jxl.mak | 16 ++
tests/ref/fate/jxl-anim-demux-belgium | 6 +
tests/ref/fate/jxl-anim-demux-icos4d | 6 +
tests/ref/fate/jxl-anim-demux-lenna256 | 7 +
tests/ref/fate/jxl-anim-demux-newton | 6 +
18 files changed, 566 insertions(+), 201 deletions(-)
create mode 100644 libavcodec/jpegxl.h
rename libavformat/jpegxl_probe.c => libavcodec/jpegxl_parse.c (65%)
create mode 100644 libavcodec/jpegxl_parse.h
create mode 100644 libavcodec/jpegxl_parser.c
rename libavformat/{jpegxl_probe.h => jpegxl_parse.c} (55%)
create mode 100644 tests/fate/jxl.mak
create mode 100644 tests/ref/fate/jxl-anim-demux-belgium
create mode 100644 tests/ref/fate/jxl-anim-demux-icos4d
create mode 100644 tests/ref/fate/jxl-anim-demux-lenna256
create mode 100644 tests/ref/fate/jxl-anim-demux-newton
--
2.41.0
More information about the ffmpeg-devel
mailing list