[FFmpeg-devel] [PATCH v2 3/3] lavu/hwcontext_qsv: fix memory leak for d3d9 impl

2023-06-18 Thread Tong Wu
Signed-off-by: Tong Wu --- libavutil/hwcontext_qsv.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/libavutil/hwcontext_qsv.c b/libavutil/hwcontext_qsv.c index 1d24a04561..82c020915d 100644 --- a/libavutil/hwcontext_qsv.c +++ b/libavutil/hwcontext_qsv.c @@ -756,

[FFmpeg-devel] [PATCH v2 2/3] lavu/hwcontext_qsv: fix memory leak for d3d11va impl

2023-06-18 Thread Tong Wu
Signed-off-by: Tong Wu --- libavutil/hwcontext_qsv.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/libavutil/hwcontext_qsv.c b/libavutil/hwcontext_qsv.c index 878ecd886e..1d24a04561 100644 --- a/libavutil/hwcontext_qsv.c +++ b/libavutil/hwcontext_qsv.c @@ -665,6

[FFmpeg-devel] [PATCH v2 1/3] avutil/hwcontext_qsv: register free function for device_derive

2023-06-18 Thread Tong Wu
When qsv device is created by device_derive, the ctx->free function is not registered, causing potential memory leak because of not properly closing the MFX session. Signed-off-by: Tong Wu Signed-off-by: Wenbin Chen --- libavutil/hwcontext_qsv.c | 9 + 1 file changed, 9 insertions(+) d

Re: [FFmpeg-devel] [PATCH 1/6] lavfi/qsvvpp: track the runtime version in vpp context

2023-06-18 Thread Xiang, Haihao
On Ma, 2023-06-12 at 16:14 +0800, Xiang, Haihao wrote: > From: Haihao Xiang > > We may check whether a feature is supported via the runtime version in > future. > > Signed-off-by: Haihao Xiang > --- >  libavfilter/qsvvpp.c | 6 ++ >  libavfilter/qsvvpp.h | 2 ++ >  2 files changed, 8 insertio

Re: [FFmpeg-devel] [PATCH 2/2] lavu/hwcontext_qsv: fix memory leak for d3d9 impl

2023-06-18 Thread Xiang, Haihao
On Vr, 2023-06-16 at 20:05 +0800, Tong Wu wrote: > Signed-off-by: Tong Wu > --- >  libavutil/hwcontext_qsv.c | 12 ++-- >  1 file changed, 10 insertions(+), 2 deletions(-) > > diff --git a/libavutil/hwcontext_qsv.c b/libavutil/hwcontext_qsv.c > index 931f905a51..4cbe8cc494 100644 > --- a/l

Re: [FFmpeg-devel] [PATCH 1/2] lavu/hwcontext_qsv: fix memory leak for d3d11va impl

2023-06-18 Thread Xiang, Haihao
On Vr, 2023-06-16 at 20:05 +0800, Tong Wu wrote: > Signed-off-by: Tong Wu > --- >  libavutil/hwcontext_qsv.c | 12 >  1 file changed, 8 insertions(+), 4 deletions(-) > > diff --git a/libavutil/hwcontext_qsv.c b/libavutil/hwcontext_qsv.c > index 713dc90ffd..931f905a51 100644 > --- a/li

Re: [FFmpeg-devel] [PATCH] avutil/hwcontext_qsv: register free function for device_derive

2023-06-18 Thread Xiang, Haihao
On Vr, 2023-06-16 at 15:27 +0800, Tong Wu wrote: > When qsv device is created by device_derive, the ctx->free function is > not registered, causing potential memory leak because of not properly > closing the MFX session. > > Signed-off-by: Tong Wu > Signed-off-by: Wenbin Chen > --- >  libavutil/

Re: [FFmpeg-devel] [PATCH v24 6/9] avformat/mov_muxer: Extended MOV muxer to handle EVC video content

2023-06-18 Thread James Almer
On 6/18/2023 11:27 PM, Wang Bin wrote: - Changes in mov_write_video_tag function to handle EVC elementary stream - Provided structure EVCDecoderConfigurationRecord that specifies the decoder configuration information for ISO/IEC 23094-1 video content Signed-off-by: Dawid Kozinski --- libavfo

Re: [FFmpeg-devel] [PATCH v24 6/9] avformat/mov_muxer: Extended MOV muxer to handle EVC video content

2023-06-18 Thread Wang Bin
- Changes in mov_write_video_tag function to handle EVC elementary stream > - Provided structure EVCDecoderConfigurationRecord that specifies the > decoder configuration information for ISO/IEC 23094-1 video content > > Signed-off-by: Dawid Kozinski > --- > libavformat/Makefile| 2 +- > lib

[FFmpeg-devel] [PATCH 17/17] avcodec/evc_ps: Check log2_sub_gop_length

2023-06-18 Thread James Almer
From: Michael Niedermayer Fixes: 1.70141e+38 is outside the range of representable values of type 'int' Fixes: 59883/clusterfuzz-testcase-minimized-ffmpeg_BSF_EVC_FRAME_MERGE_fuzzer-5557887217565696 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ff

[FFmpeg-devel] [PATCH 16/17] avcodec/evc_ps: make ff_evc_parse_{sps, pps} return an error code

2023-06-18 Thread James Almer
Signed-off-by: James Almer --- libavcodec/evc_frame_merge_bsf.c | 17 +- libavcodec/evc_parser.c | 18 +-- libavcodec/evc_ps.c | 54 ++-- libavcodec/evc_ps.h | 4 +-- 4 files changed, 48 insertions(+), 45 deletions(-)

[FFmpeg-devel] [PATCH 15/17] avformat/evcdec: don't set AVCodecParameters.framerate

2023-06-18 Thread James Almer
It's not necessary. Setting AVStream.avg_frame_rate is enough. Signed-off-by: James Almer --- libavformat/evcdec.c | 1 - 1 file changed, 1 deletion(-) diff --git a/libavformat/evcdec.c b/libavformat/evcdec.c index a3a41cb4a5..3cadbc1530 100644 --- a/libavformat/evcdec.c +++ b/libavformat/evcde

[FFmpeg-devel] [PATCH 14/17] avformat/evcdec: simplify au_end_found check

2023-06-18 Thread James Almer
Signed-off-by: James Almer --- libavformat/evcdec.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/libavformat/evcdec.c b/libavformat/evcdec.c index 7a783e9809..a3a41cb4a5 100644 --- a/libavformat/evcdec.c +++ b/libavformat/evcdec.c @@ -144,7 +144,7 @@ static int evc

[FFmpeg-devel] [PATCH 13/17] avformat/evcdec: simplify probe function

2023-06-18 Thread James Almer
Signed-off-by: James Almer --- libavformat/evcdec.c | 29 +++-- 1 file changed, 7 insertions(+), 22 deletions(-) diff --git a/libavformat/evcdec.c b/libavformat/evcdec.c index 0f17edd371..7a783e9809 100644 --- a/libavformat/evcdec.c +++ b/libavformat/evcdec.c @@ -34,14 +3

[FFmpeg-devel] [PATCH 12/17] avformat/evcdec: deduplicate nalu length and type parsing functions

2023-06-18 Thread James Almer
Signed-off-by: James Almer --- libavformat/evcdec.c | 46 1 file changed, 4 insertions(+), 42 deletions(-) diff --git a/libavformat/evcdec.c b/libavformat/evcdec.c index 807406885a..0f17edd371 100644 --- a/libavformat/evcdec.c +++ b/libavformat/evcdec

[FFmpeg-devel] [PATCH 11/17] avformat/evc: don't use an AVIOContext as log context

2023-06-18 Thread James Almer
Signed-off-by: James Almer --- libavcodec/evc_parse.h | 3 ++- libavformat/evc.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/libavcodec/evc_parse.h b/libavcodec/evc_parse.h index a1fbbc643d..677e01a64a 100644 --- a/libavcodec/evc_parse.h +++ b/libavcodec/evc_pars

Re: [FFmpeg-devel] [PATCH 4/6] avcodec/evc_parse: Check log2_sub_gop_length

2023-06-18 Thread James Almer
On 6/18/2023 7:27 PM, James Almer wrote: On 6/18/2023 6:50 PM, Michael Niedermayer wrote: Fixes: 1.70141e+38 is outside the range of representable values of type 'int' Fixes: 59883/clusterfuzz-testcase-minimized-ffmpeg_BSF_EVC_FRAME_MERGE_fuzzer-5557887217565696 Found-by: continuous fuzzing p

Re: [FFmpeg-devel] [PATCH 3/6] avformat/jpegxl_anim_dec: add FF_JPEGXL_CONTAINER_SIGNATURE_LE

2023-06-18 Thread Leo Izen
On 6/18/23 17:50, Michael Niedermayer wrote: Fixes: out of array read Fixes: 59828/clusterfuzz-testcase-minimized-ffmpeg_dem_JPEGXL_ANIM_fuzzer-5029813220671488 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermaye

[FFmpeg-devel] [PATCH 3/6] avformat/jpegxl_anim_dec: add FF_JPEGXL_CONTAINER_SIGNATURE_LE

2023-06-18 Thread Michael Niedermayer
Fixes: out of array read Fixes: 59828/clusterfuzz-testcase-minimized-ffmpeg_dem_JPEGXL_ANIM_fuzzer-5029813220671488 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavformat/jpegxl_anim_dec.c | 13

[FFmpeg-devel] [PATCH 5/6] avcodec/vmixdec: Fix several integer anomalies

2023-06-18 Thread Michael Niedermayer
Fixes: vmixdec.c:132:34: runtime error: signed integer overflow: -2147483648 * 1856 cannot be represented in type 'int' Fixes: vmixdec.c:119:20: runtime error: signed integer overflow: -1256 + -2147483648 cannot be represented in type 'int' Fixes: vmixdec.c:137:36: runtime error: signed integer o

[FFmpeg-devel] [PATCH v2] avformat: add Software Defined Radio support

2023-06-18 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- configure|4 + doc/demuxers.texi| 71 ++ libavformat/Makefile |2 + libavformat/allformats.c |2 + libavformat/sdrdemux.c | 1739 ++ 5 files changed, 1818 insertions(+) create m

Re: [FFmpeg-devel] [PATCH 4/6] avcodec/evc_parse: Check log2_sub_gop_length

2023-06-18 Thread James Almer
On 6/18/2023 6:50 PM, Michael Niedermayer wrote: Fixes: 1.70141e+38 is outside the range of representable values of type 'int' Fixes: 59883/clusterfuzz-testcase-minimized-ffmpeg_BSF_EVC_FRAME_MERGE_fuzzer-5557887217565696 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/

[FFmpeg-devel] [PATCH 2/6] avcodec/utils: fix 2 integer overflows in get_audio_frame_duration()

2023-06-18 Thread Michael Niedermayer
Fixes: signed integer overflow: 256 * 668003712 cannot be represented in type 'int' Fixes: 59819/clusterfuzz-testcase-minimized-ffmpeg_dem_MATROSKA_fuzzer-4674636538052608 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael

Re: [FFmpeg-devel] [PATCH 1/6] avformat/jpegxl_anim_dec: Perform operations in a different order

2023-06-18 Thread Leo Izen
On 6/18/23 17:50, Michael Niedermayer wrote: Fixes: OOM Fixes: 59802/clusterfuzz-testcase-minimized-ffmpeg_dem_JPEGXL_ANIM_fuzzer-5681765466112000 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libav

Re: [FFmpeg-devel] [PATCH 6/6] doc/developer: Require new modules to include tests

2023-06-18 Thread Lynne
Jun 18, 2023, 23:50 by mich...@niedermayer.cc: > Signed-off-by: Michael Niedermayer > --- > doc/developer.texi | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/doc/developer.texi b/doc/developer.texi > index a7da2ce2d5..0c2f2cd7d1 100644 > --- a/doc/developer.texi > +

[FFmpeg-devel] [PATCH 6/6] doc/developer: Require new modules to include tests

2023-06-18 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- doc/developer.texi | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/developer.texi b/doc/developer.texi index a7da2ce2d5..0c2f2cd7d1 100644 --- a/doc/developer.texi +++ b/doc/developer.texi @@ -805,7 +805,10 @@ Lines with similar c

[FFmpeg-devel] [PATCH 4/6] avcodec/evc_parse: Check log2_sub_gop_length

2023-06-18 Thread Michael Niedermayer
Fixes: 1.70141e+38 is outside the range of representable values of type 'int' Fixes: 59883/clusterfuzz-testcase-minimized-ffmpeg_BSF_EVC_FRAME_MERGE_fuzzer-5557887217565696 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael

[FFmpeg-devel] [PATCH 1/6] avformat/jpegxl_anim_dec: Perform operations in a different order

2023-06-18 Thread Michael Niedermayer
Fixes: OOM Fixes: 59802/clusterfuzz-testcase-minimized-ffmpeg_dem_JPEGXL_ANIM_fuzzer-5681765466112000 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavformat/jpegxl_anim_dec.c | 2 +- 1 file changed,

Re: [FFmpeg-devel] [PATCH v1 1/2] lavc/vp9: set yuvj pixel format for full range decode

2023-06-18 Thread Leo Izen
On 6/17/23 10:26, Thilo Borgmann wrote: Am 17.06.23 um 16:02 schrieb Leo Izen: On 6/17/23 04:11, Thilo Borgmann wrote: While the yuvj pixel formats are deprecated lots of code still relies on them to be set. Without setting a yuvj420p pixel format VP9 decoding ends up incorrectly due to auto co

Re: [FFmpeg-devel] [PATCH] web/consulting: add myself

2023-06-18 Thread Michael Niedermayer
On Sun, Jun 18, 2023 at 11:21:56AM +0200, Anton Khirnov wrote: > --- > src/consulting | 12 > 1 file changed, 12 insertions(+) LGTM thx [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Asymptotically faster algorithms should always be preferred if

[FFmpeg-devel] [PATCH] MAINTAINERS: change Leo Izen IRC nickname

2023-06-18 Thread Leo Izen
I use a different nick on IRC now, Traneptora, instead of what I formerly used, thebombzen. Signed-off-by: --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index f6a0f9bcb5..48b98809b8 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -617

Re: [FFmpeg-devel] [PATCH v2] avformat/jpegxl_anim_dec: avoid overrun with jxlp boxes in container

2023-06-18 Thread Leo Izen
On 6/16/23 14:35, Leo Izen wrote: On 6/12/23 09:22, Leo Izen wrote: This switches the jpegxl_collect_codestream_header function to use avcodec/bytestream2, which better enforces barriers, and should avoid overrunning buffers with jxlp boxes if the size is zero or if the size is so small the box

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Michael Niedermayer
On Sun, Jun 18, 2023 at 02:59:37PM +0200, Lynne wrote: > Jun 17, 2023, 20:37 by mich...@niedermayer.cc: > > > On Sat, Jun 17, 2023 at 08:08:11PM +0200, Paul B Mahol wrote: > > [...] > > > >> Which library handles compressed stuff? > >> > > > > For digital stuff like DAB/DVB/... > > > > sdrdemux in

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Lynne
Jun 18, 2023, 15:30 by h.lepp...@gmail.com: > On Sun, Jun 18, 2023 at 2:59 PM Lynne wrote: > >> >> Jun 17, 2023, 20:37 by mich...@niedermayer.cc: >> >> > On Sat, Jun 17, 2023 at 08:08:11PM +0200, Paul B Mahol wrote: >> > [...] >> > >> >> Which library handles compressed stuff? >> >> >> > >> > For

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Hendrik Leppkes
On Sun, Jun 18, 2023 at 2:59 PM Lynne wrote: > > Jun 17, 2023, 20:37 by mich...@niedermayer.cc: > > > On Sat, Jun 17, 2023 at 08:08:11PM +0200, Paul B Mahol wrote: > > [...] > > > >> Which library handles compressed stuff? > >> > > > > For digital stuff like DAB/DVB/... > > > > sdrdemux in libavfo

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Lynne
Jun 17, 2023, 20:37 by mich...@niedermayer.cc: > On Sat, Jun 17, 2023 at 08:08:11PM +0200, Paul B Mahol wrote: > [...] > >> Which library handles compressed stuff? >> > > For digital stuff like DAB/DVB/... > > sdrdemux in libavformat will demodulate, do error correction then return > AVPacket >

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Kieran Kunhya
On Sun, 18 Jun 2023 at 23:46, Paul B Mahol wrote: > > sdrdemux in libavformat will demodulate, do error correction then return > > AVPacket > > with H.264 / Mpeg2 video or AAC or wahetever > > That then will get passed to libavcodec, same as with any other demuxer. > Whilst I agree that there is

Re: [FFmpeg-devel] [PATCH] vulkan_decode: use the hwfc->user_opaque field to store the profile

2023-06-18 Thread Lynne
Jun 18, 2023, 14:20 by d...@lynne.ee: > Patch attached. > Forgot to git add -p to fix a memory leak on failure. >From 26159eb0772d51800740c6221f7ee1c44e01aa6e Mon Sep 17 00:00:00 2001 From: Lynne Date: Tue, 13 Jun 2023 06:10:20 +0200 Subject: [PATCH] vulkan_decode: use the hwfc->user_opaque fiel

Re: [FFmpeg-devel] [PATCH 2/5] vulkan_decode: use the new AVHWFramesContext.opaque field

2023-06-18 Thread Lynne
Jun 18, 2023, 13:10 by an...@khirnov.net: > Quoting Lynne (2023-06-13 14:53:35) > >> Jun 13, 2023, 14:29 by an...@khirnov.net: >> >> > Quoting Lynne (2023-06-13 06:19:34) >> > >> >> This depends on the previous patch, and allows moving the codec >> >> profile to the new AVHWFramesContext.opaque fi

[FFmpeg-devel] [PATCH] vulkan_decode: use the hwfc->user_opaque field to store the profile

2023-06-18 Thread Lynne
Patch attached. >From fe6516e22880a067420a6e21a6928ad176f66b45 Mon Sep 17 00:00:00 2001 From: Lynne Date: Tue, 13 Jun 2023 06:10:20 +0200 Subject: [PATCH] vulkan_decode: use the hwfc->user_opaque field to store the profile --- libavcodec/vulkan_decode.c | 60 ---

Re: [FFmpeg-devel] [PATCH] avcodec: Ignoring errors is only possible before the input end

2023-06-18 Thread Michael Niedermayer
On Sat, Jun 17, 2023 at 08:45:53AM +0200, Paul B Mahol wrote: > On Sat, Jun 3, 2023 at 9:44 PM Michael Niedermayer > wrote: > > > Fixes: out of array read > > Fixes: Ticket 10308 > > > > Did you forgot to apply this? yes, ill apply it with my next git push thx for reminding me [...] -- Micha

Re: [FFmpeg-devel] [PATCH] avformat/avcodec: Add DTS-UHD demuxer and parser, movenc support.

2023-06-18 Thread Paul B Mahol
On Thu, Jun 15, 2023 at 8:45 PM Roy Funderburk wrote: > > > On 6/15/23 8:46 AM, Paul B Mahol wrote: > > get_vlc2 can be made for get_bits_var(), first table bits (that are still > > int and not uint8_t), the code that picks table index from which to take > > bits. > > > > It is also possible to m

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/rka: use unsigned for buf0 additions

2023-06-18 Thread Michael Niedermayer
On Thu, Jun 08, 2023 at 07:18:23PM +0200, Michael Niedermayer wrote: > Fixes: signed integer overflow: -38912000 + -2109276160 cannot be represented > in type 'int' > Fixes: > 59670/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_RKA_fuzzer-4987563245699072 > > Found-by: continuous fuzzing pro

Re: [FFmpeg-devel] [PATCH 2/5] avcodec/takdsp: Fix integer overflows

2023-06-18 Thread Michael Niedermayer
On Thu, May 25, 2023 at 11:40:16PM +0200, Michael Niedermayer wrote: > Fixes: avcodec/takdsp.c:44:23: runtime error: signed integer overflow: > -2097158 - 2147012608 cannot be represented in type 'int' > Fixes: > 58417/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TAK_fuzzer-526891966464

Re: [FFmpeg-devel] [PATCH 08/10] avcodec/evc_parser: remove write only variable

2023-06-18 Thread Paul B Mahol
lgtm ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 5/5] avformat: add sdr support

2023-06-18 Thread Paul B Mahol
On Sat, Jun 17, 2023 at 8:37 PM Michael Niedermayer wrote: > On Sat, Jun 17, 2023 at 08:08:11PM +0200, Paul B Mahol wrote: > [...] > > > Which library handles compressed stuff? > > For digital stuff like DAB/DVB/... > > sdrdemux in libavformat will demodulate, do error correction then return > AV

Re: [FFmpeg-devel] [PATCH] avcodec: use sRGB to stringify gbr/bt709/iec61966-2-1 instead

2023-06-18 Thread Derek Buitenhuis
On 6/17/2023 7:07 PM, Leo Izen wrote: > -if (strcmp(col, pri) || strcmp(col, trc)) { > +if (enc->colorspace == AVCOL_SPC_RGB && > +enc->color_primaries == AVCOL_PRI_BT709 && > +enc->color_trc == AVCOL_TRC_IEC61966_2_1)

[FFmpeg-devel] [PATCH v2 14/22] lavfi/vf_libplacebo: only drain actually used PTS

2023-06-18 Thread Niklas Haas
From: Niklas Haas When combining multiple inputs, the output PTS may be less than the PTS of the input. In this case, the current's code assumption of always draining one value from the FIFO is incorrect. Replace by a smarter function which drains only those PTS values that were actually consumed

[FFmpeg-devel] [PATCH v2 13/22] lavfi/vf_libplacebo: determine PTS of next frame from any input

2023-06-18 Thread Niklas Haas
From: Niklas Haas When combining multiple inputs with different PTS and durations, in input-timed mode, we emit one output frame for every input frame PTS, from *any* input. So when combining a low FPS stream with a high FPS stream, the output framerate would match the higher FPS, independent of

[FFmpeg-devel] [PATCH v2 12/22] lavfi/vf_libplacebo: handle multiple inputs

2023-06-18 Thread Niklas Haas
From: Niklas Haas This commit still relies on a single input for PTS determination, to be changed in the next commit. --- libavfilter/vf_libplacebo.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index 5ea6fc

[FFmpeg-devel] [PATCH v2 11/22] lavfi/vf_libplacebo: support blending multiple inputs

2023-06-18 Thread Niklas Haas
From: Niklas Haas Subsequent inputs require frame blending to be enabled, in order to not overwrite the existing frame contents. For output metadata, we implicitly copy the metadata of the *first* available stream (falling back to the second stream if the first has already reached EOF, and so on

[FFmpeg-devel] [PATCH v2 10/22] lavfi/vf_libplacebo: keep track of latest status globally

2023-06-18 Thread Niklas Haas
From: Niklas Haas This field will effectively hold the most recent status set by any input. Currently functionally equivalent to input->status, but will change soon. --- libavfilter/vf_libplacebo.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/libavfilter/vf_lib

[FFmpeg-devel] [PATCH v2 09/22] lavfi/vf_libplacebo: replace s->input by dynamic array

2023-06-18 Thread Niklas Haas
From: Niklas Haas For now, hard-coded to 1 element. --- libavfilter/vf_libplacebo.c | 20 +++- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index 408fb3918aa..ee8780036cf 100644 --- a/libavfilter/vf_libpl

[FFmpeg-devel] [PATCH v2 08/22] lavfi/vf_libplacebo: use correct link in update_crops()

2023-06-18 Thread Niklas Haas
From: Niklas Haas Instead of hard-coding input 0, pass the per-input structure and use the link contained inside it. --- libavfilter/vf_libplacebo.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index

[FFmpeg-devel] [PATCH v2 07/22] lavfi/vf_libplacebo: factor out ref frame logic

2023-06-18 Thread Niklas Haas
From: Niklas Haas Instead of finding the ref frame in output_frame() and then passing its signature to update_crops(), pull out the logic and invoke it a second time inside update_crops(). This may seem wasteful at present, but will actually become required in the future, since update_crops() ru

[FFmpeg-devel] [PATCH v2 22/22] lavfi/vf_libplacebo: add nb_inputs option

2023-06-18 Thread Niklas Haas
From: Niklas Haas To control the number of inputs. --- doc/filters.texi| 5 + libavfilter/vf_libplacebo.c | 25 ++--- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index cf17930b014..c3d3f004b19 100644 --

[FFmpeg-devel] [PATCH v2 20/22] lavfi/vf_libplacebo: also skip cache if in FPS == out FPS

2023-06-18 Thread Niklas Haas
From: Niklas Haas Fixes an oversight in the previous code which should have been >=, not >. --- libavfilter/vf_libplacebo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index f7b9bdba742..1085b6fdd0a 100644 --- a/li

[FFmpeg-devel] [PATCH v2 21/22] lavfi/vf_libplacebo: set time_base/frame_rate dynamically

2023-06-18 Thread Niklas Haas
From: Niklas Haas Use the gcd of all input timebases to ensure PTS accuracy. For the framerate, just pick the highest of all the inputs, under the assumption that we will render frames with approximately this frequency. Of course, this is not 100% accurate, in particular if the input frames are b

[FFmpeg-devel] [PATCH v2 19/22] lavfi/vf_libplacebo: skip cache selectively per-input

2023-06-18 Thread Niklas Haas
From: Niklas Haas It may be the case that we want to skip the single frame cache for some inputs but not others. --- libavfilter/vf_libplacebo.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index 627223256c6.

[FFmpeg-devel] [PATCH v2 18/22] lavfi/vf_libplacebo: set format list for all inputs

2023-06-18 Thread Niklas Haas
From: Niklas Haas --- libavfilter/vf_libplacebo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index fcd3ad07e2c..627223256c6 100644 --- a/libavfilter/vf_libplacebo.c +++ b/libavfilter/vf_libplacebo.c @@ -1131,7 +

[FFmpeg-devel] [PATCH v2 16/22] lavfi/vf_libplacebo: make input-dependent vars dynamic

2023-06-18 Thread Niklas Haas
From: Niklas Haas Because these can differ based on the input, for multiple inputs. --- libavfilter/vf_libplacebo.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index 6399aae0c67..a3a034766e2 100644 --- a

[FFmpeg-devel] [PATCH v2 17/22] lavfi/vf_libplacebo: add in_idx variable

2023-06-18 Thread Niklas Haas
From: Niklas Haas To allow placing an input dynamically, as a function of the input index. --- doc/filters.texi| 2 ++ libavfilter/vf_libplacebo.c | 9 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index 5e25cf293e5..cf17

[FFmpeg-devel] [PATCH v2 15/22] lavfi/vf_libplacebo: generalize frame update to multiple inputs

2023-06-18 Thread Niklas Haas
From: Niklas Haas In the event that some frame mixes are OK while others are not, the priority goes: 1. Errors in updating any frame -> return error 2. Any input incomplete -> request frames and return 3. Any inputs OK -> ignore EOF streams and render remaining inputs 4. No inputs OK -> set outp

[FFmpeg-devel] [PATCH v2 06/22] lavif/vf_libplacebo: remove pl_frame_mix from output_frame_mix

2023-06-18 Thread Niklas Haas
From: Niklas Haas Instead, rename this function to `output_frame` and make it pull the `pl_frame_mix` from the input structure. Step towards handling multiple inputs. --- libavfilter/vf_libplacebo.c | 23 +++ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/lib

[FFmpeg-devel] [PATCH v2 05/22] lavfi/vf_libplacebo: move temporary vars into per-input struct

2023-06-18 Thread Niklas Haas
From: Niklas Haas Including the queue status, because these will need to be re-queried inside output_frame_mix when that function is refactored to handle multiple inputs. --- libavfilter/vf_libplacebo.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/libavfilter/v

[FFmpeg-devel] [PATCH v2 04/22] lavfi/vf_libplacebo: cosmetic

2023-06-18 Thread Niklas Haas
From: Niklas Haas Assign local variable 'in' for 's->input' and replace 'inlink' by 'in->link' to avoid hard-coding ID 0 in more than one place. --- libavfilter/vf_libplacebo.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/libavfilter/vf_libplaceb

[FFmpeg-devel] [PATCH v2 03/22] lavfi/vf_libplacebo: move input handling to separate function

2023-06-18 Thread Niklas Haas
From: Niklas Haas To be re-used once we support more than one input. --- libavfilter/vf_libplacebo.c | 45 - 1 file changed, 29 insertions(+), 16 deletions(-) diff --git a/libavfilter/vf_libplacebo.c b/libavfilter/vf_libplacebo.c index 10fd4327458..879a3a0508

[FFmpeg-devel] [PATCH v2 02/22] lavfi/vf_libplacebo: move input-specific state to struct

2023-06-18 Thread Niklas Haas
From: Niklas Haas In anticipation of a refactor which will enable multiple input support. Note: the renderer is also input-specific because it maintains a frame cache, HDR peak detection state and mixing cache, all of which are tied to a specific input stream. --- libavfilter/vf_libplacebo.c |

[FFmpeg-devel] [PATCH v2 01/22] lavfi/vf_libplacebo: drop redundant case

2023-06-18 Thread Niklas Haas
From: Niklas Haas If the input queue is EOF, then the s->status check should already have covered it, and prevented the code from getting this far. If we still hit this case for some reason, it's probably a bug. Better to hit the AVERROR_BUG branch. --- libavfilter/vf_libplacebo.c | 3 --- 1 fi

[FFmpeg-devel] lavfi/vf_libplacebo: generalize to multiple inputs

2023-06-18 Thread Niklas Haas
Changes since v1: - added explicit `if (s->inputs)` check to input_uninit() loop - added extra `!s->status` check to handle case of negative PTS on status change (since `s->status_pts >= 0` would fail here) ___ ffmpeg-devel mailing list ffmpeg-devel@f

Re: [FFmpeg-devel] [PATCH 2/5] vulkan_decode: use the new AVHWFramesContext.opaque field

2023-06-18 Thread Anton Khirnov
Quoting Lynne (2023-06-13 14:53:35) > Jun 13, 2023, 14:29 by an...@khirnov.net: > > > Quoting Lynne (2023-06-13 06:19:34) > > > >> This depends on the previous patch, and allows moving the codec > >> profile to the new AVHWFramesContext.opaque field. > >> > >> Patch attached. > >> > >> > >> From f

Re: [FFmpeg-devel] [RFC] [PATCH 1/5] hwcontext: add a new AVHWFramesContext.opaque field

2023-06-18 Thread Lynne
Jun 16, 2023, 13:02 by d...@lynne.ee: > Jun 13, 2023, 19:18 by d...@lynne.ee: > >> Jun 13, 2023, 18:56 by andreas.rheinha...@outlook.com: >> >>> Lynne: >>> +dst->opaque= av_buffer_ref(src->opaque); +if (!dst->opaque) { +ret = AVERROR(ENOMEM); +goto f

Re: [FFmpeg-devel] [PATCH] Optimization: support for libx264's mb_info

2023-06-18 Thread Stefano Sabatini
On date Monday 2023-06-12 17:28:10 +, Carotti, Elias wrote: > Hi Stefano, > Here is the revised patch according to your suggestions. This should > allow for efficient inlining of the methods computing the map of > skipped macrobloks. > Best,  > Elias [...] > > From 0e7979250231edbe0b845cee96c

Re: [FFmpeg-devel] [PATCH] Optimization: support for libx264's mb_info

2023-06-18 Thread Stefano Sabatini
On date Monday 2023-06-12 17:38:43 +, Carotti, Elias wrote: > On Mon, 2023-06-12 at 18:23 +1000, Kieran Kunhya wrote: > > CAUTION: This email originated from outside of the organization. Do > > not click links or open attachments unless you can confirm the sender > > and know the content is saf

[FFmpeg-devel] [PATCH] web/consulting: add myself

2023-06-18 Thread Anton Khirnov
--- src/consulting | 12 1 file changed, 12 insertions(+) diff --git a/src/consulting b/src/consulting index c2c78fc..70a88e5 100644 --- a/src/consulting +++ b/src/consulting @@ -144,4 +144,16 @@ E.g.: + + + Anton Khirnov + +Anton is locat

Re: [FFmpeg-devel] [PATCH 01/21] fftools/ffmpeg_dec: drop always-0 InputStream.prev_sub.ret

2023-06-18 Thread Anton Khirnov
Will push the set tomorrow if nobody has further comments. -- Anton Khirnov ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.or

Re: [FFmpeg-devel] [PATCH 1/5] lavc/aarch64: new optimization for 8-bit hevc_pel_uni_pixels

2023-06-18 Thread Logan.Lyu
Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: The platform I tested is the g8y instance of Alibaba Cloud, with a chip based on armv9. put_hevc_pel_uni_pixels4_8_c: 35.9 put_hevc_pel_uni_pixels

Re: [FFmpeg-devel] [PATCH 4/5] lavc/aarch64: new optimization for 8-bit hevc_epel_h

2023-06-18 Thread Logan.Lyu
Add missing patch attachment... 在 2023/6/18 16:23, Logan.Lyu 写道: Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: put_hevc_epel_h4_8_c: 67.1 put_hevc_epel_h4_8_i8mm: 21.1 put_hevc_epel_h6_8_c: 147.

Re: [FFmpeg-devel] [PATCH 5/5] lavc/aarch64: new optimization for 8-bit hevc_epel_uni_w_hv

2023-06-18 Thread Logan.Lyu
Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: put_hevc_epel_uni_w_hv4_8_c: 254.6 put_hevc_epel_uni_w_hv4_8_i8mm: 102.9 put_hevc_epel_uni_w_hv6_8_c: 411.6 put_hevc_epel_uni_w_hv6_8_i8mm: 221.6 put_

Re: [FFmpeg-devel] [PATCH 4/5] lavc/aarch64: new optimization for 8-bit hevc_epel_h

2023-06-18 Thread Logan.Lyu
Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: put_hevc_epel_h4_8_c: 67.1 put_hevc_epel_h4_8_i8mm: 21.1 put_hevc_epel_h6_8_c: 147.1 put_hevc_epel_h6_8_i8mm: 45.1 put_hevc_epel_h8_8_c: 237.4 put_hev

Re: [FFmpeg-devel] [PATCH 3/5] lavc/aarch64: new optimization for 8-bit hevc_epel_uni_w_v

2023-06-18 Thread Logan.Lyu
Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: put_hevc_epel_uni_w_v4_8_c: 116.1 put_hevc_epel_uni_w_v4_8_neon: 48.6 put_hevc_epel_uni_w_v6_8_c: 248.9 put_hevc_epel_uni_w_v6_8_neon: 80.6 put_hevc_

Re: [FFmpeg-devel] [PATCH 2/5] lavc/aarch64: new optimization for 8-bit hevc_epel_uni_w_h

2023-06-18 Thread Logan.Lyu
Hi, Martin, I modified it according to your comments. Please review again. And here are the checkasm benchmark results of the related functions: put_hevc_epel_uni_w_h4_8_c: 126.1 put_hevc_epel_uni_w_h4_8_i8mm: 41.6 put_hevc_epel_uni_w_h6_8_c: 222.9 put_hevc_epel_uni_w_h6_8_i8mm: 91.4 put_hevc_e

Re: [FFmpeg-devel] [PATCH v1 2/2] lavc/libvpxenc: support creating full range output

2023-06-18 Thread Thilo Borgmann
Am 18.06.23 um 02:03 schrieb James Zern: On Sat, Jun 17, 2023 at 1:11 AM Thilo Borgmann wrote: suggested-by: ffm...@meta.com --- libavcodec/libvpxenc.c | 12 1 file changed, 12 insertions(+) Looks like there's some discussion on the parent patch about the correctness of addi