[FFmpeg-devel] [PATCH] avutil/opt: add AV_OPT_FLAG_FORCE_CONST
Michael Niedermayer
michael at niedermayer.cc
Tue Apr 16 03:07:17 EEST 2024
On Sun, Apr 14, 2024 at 10:35:57PM +0200, Timo Rothenpieler wrote:
> On 14.04.2024 22:30, Marton Balint wrote:
> >
> >
> > On Sun, 14 Apr 2024, Timo Rothenpieler wrote:
> >
> > > ---
> > > doc/APIchanges | 3 +++
> > > libavutil/opt.c | 14 ++++++++++++++
> > > libavutil/opt.h | 5 +++++
> > > libavutil/version.h | 2 +-
> > > 4 files changed, 23 insertions(+), 1 deletion(-)
> >
> > Where do you intend to use this flag? So some justification or
> > description of your plans is missing from the commit message.
>
> Some options in nvenc could be greatly simplified with it, where right now
> there's multiple if/switch-trees in the code, just to weed out invalid
> values.
This doesnt feel right.
The code would need to validate the actual value the same way it
checks min/max at least
avoptions allows the user to obtain a parameters address and set
it directly as well as set it without any AVOption
iam still not sure thats a good idea.
Why are the values not in a continous sequence of integers that can
be checked with min/max ?
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
While the State exists there can be no freedom; when there is freedom there
will be no State. -- Vladimir Lenin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20240416/79f1c464/attachment.sig>
More information about the ffmpeg-devel
mailing list