From: Niklas Haas <ffmpeg@haasn.xyz>
To: ffmpeg-devel@ffmpeg.org
Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec: add YUV color space metadata to AVCodec
Date: Mon, 5 Feb 2024 19:37:48 +0100
Message-ID: <20240205193748.GB37488@haasn.xyz> (raw)
In-Reply-To: <AS8P250MB07445C2AB7A6ACA1FE4E06178F472@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM>
On Mon, 05 Feb 2024 19:04:30 +0100 Andreas Rheinhardt <andreas.rheinhardt@outlook.com> wrote:
> This presumes the relevant states to be a cartesian product. Which need
> not be true. A callback would be better; this would also allow to base
> the list on other values already set in an AVCodecContext. And if this
> were extended, it would also allow to remove init_static_data one day.
> It is furthermore quite wasteful to store color_ranges in a list,
> although there are only very few states for it.
What signature would you propose for such a callback?
I disagree with using a list for the range being wasteful. In terms of
binary size, they are shared (see ff_color_range_mpeg/jpeg definition).
At best you are saving a few bits from using an int bitmask instead of
a pointer.
The main reason to use a list is API simplicity and consistency. Working
with a bitmask is more awkward and would require more specialized code
as opposed to the current design which allows simply re-using macros
like DEF_CHOOSE_FORMATS in fftools, which is designed to handle lists.
Not to mention the equivalent libavfilter API also being list-based.
_______________________________________________
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:[~2024-02-05 18:37 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-05 17:44 Niklas Haas
2024-02-05 17:44 ` [FFmpeg-devel] [PATCH 2/2] avcodec: set color_ranges for all video encoders Niklas Haas
2024-02-05 17:48 ` [FFmpeg-devel] [PATCH 1/2] avcodec: add YUV color space metadata to AVCodec Niklas Haas
2024-02-05 18:04 ` Andreas Rheinhardt
2024-02-05 18:37 ` Niklas Haas [this message]
2024-02-08 11:30 ` Niklas Haas
2024-02-08 12:33 ` Andreas Rheinhardt
2024-02-08 20:32 ` Niklas Haas
2024-03-24 12:25 ` Andreas Rheinhardt
2024-02-09 12:11 ` Niklas Haas
2024-03-23 17:51 ` Niklas Haas
2024-03-24 13:04 ` Andreas Rheinhardt
2024-04-03 18:55 ` Niklas Haas
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=20240205193748.GB37488@haasn.xyz \
--to=ffmpeg@haasn.xyz \
--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