From: Leo Izen <leo.izen@gmail.com>
To: ffmpeg-devel@ffmpeg.org
Subject: Re: [FFmpeg-devel] [PATCH v14 4/4] avformat/image2: add Jpeg XL as image2 format
Date: Fri, 15 Apr 2022 15:38:30 -0400
Message-ID: <a9972488-9d32-3e06-e84f-ee0b9708ebeb@gmail.com> (raw)
In-Reply-To: <AS8PR01MB7944B49744DD95F3D94283B98FEE9@AS8PR01MB7944.eurprd01.prod.exchangelabs.com>
On 4/15/22 07:34, Andreas Rheinhardt wrote:
> Leo Izen:
>> +static int jpegxl_probe(const AVProbeData *p)
>> +{
>> + const uint8_t *b = p->buf;
>> +
>> + /* ISOBMFF-based container */
>> + /* 0x4a584c20 == "JXL " */
>> + if (AV_RL64(b) == FF_JPEGXL_CONTAINER_SIGNATURE_LE)
>> + return AVPROBE_SCORE_EXTENSION + 1;
>> + /* Raw codestreams all start with 0xff0a */
>> + if (AV_RL16(b) != FF_JPEGXL_CODESTREAM_SIGNATURE_LE)
>> + return 0;
>> + if (ff_jpegxl_verify_codestream_header(p->buf, p->buf_size) >= 0)
> This will give a linking failure if the image_jpegxl_pipe_demuxer is
> disabled.
>
I thought of that, and I tested it, and it doesn't. It produces a
compiler warning that the static function jpegxl_probe is never called,
which means the linker probably throws away the function entirely, thus
eliminating a linking error. Though I admit that's a guess.
> For the record: I'm not really ok with duplicating this code in lavf and
> lavc.
>
This code was removed from avcodec when I moved it over to avformat, for
now, in order to avoid an avpriv in avcodec's ABI. Essentially we have
to decide to either duplicate code in the future, or move it to avcodec
and add an avpriv to the ABI, but that is a decision that can be made
down the road when Lynne finishes her proper parser. I believe this is a
better solution now than the other way around since we can later change
our minds once there will actually be duplicated code, but an avpriv
cannot be removed once added without waiting the necessary ABI change
period.
- Leo Izen (thebombzen)
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2022-04-15 19:38 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-12 5:53 [FFmpeg-devel] [PATCH v14 0/4] Jpeg XL Patch Set Leo Izen
2022-04-12 5:53 ` [FFmpeg-devel] [PATCH v14 1/4] avcodec/jpegxl: add Jpeg XL image codec Leo Izen
2022-04-12 5:53 ` [FFmpeg-devel] [PATCH v14 2/4] avcodec/libjxl: add Jpeg XL decoding via libjxl Leo Izen
2022-04-15 11:08 ` Andreas Rheinhardt
2022-04-15 19:31 ` Leo Izen
2022-04-12 5:53 ` [FFmpeg-devel] [PATCH v14 3/4] avcodec/libjxl: add Jpeg XL encoding " Leo Izen
2022-04-14 17:49 ` Anton Khirnov
2022-04-15 1:37 ` Leo Izen
2022-04-15 10:39 ` Anton Khirnov
2022-04-15 19:32 ` Leo Izen
2022-04-12 5:53 ` [FFmpeg-devel] [PATCH v14 4/4] avformat/image2: add Jpeg XL as image2 format Leo Izen
2022-04-15 11:34 ` Andreas Rheinhardt
2022-04-15 19:38 ` Leo Izen [this message]
2022-04-15 19:41 ` Andreas Rheinhardt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a9972488-9d32-3e06-e84f-ee0b9708ebeb@gmail.com \
--to=leo.izen@gmail.com \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git