Re: [FFmpeg-devel] [PATCH 1/2] lavc/qsvdec: fix keyframes

2024-05-26 Thread Xiang, Haihao
On Vr, 2024-05-24 at 13:20 +0800, Xiang, Haihao wrote: > From: Haihao Xiang > > MFX_FRAMETYPE_IDR is ORed to the frame type for AVC and HEVC keyframes, > and MFX_FRAMETYPE_I is taken as keyframe flag for other codecs when > getting the output surface from the SDK, hence we may mark the output > f

Re: [FFmpeg-devel] [PATCH 07/17] qsv: Initialize impl_value

2024-05-26 Thread Xiang, Haihao
On Ma, 2024-05-27 at 01:52 +0200, Michael Niedermayer wrote: > Fixes: The warnings from CID1598553 Uninitialized scalar variable > > Passing partly initialized structs is ugly and asking for hard to reproduce > bugs, > I do not know if this actually fixes a bug or just avoids the uninitialized > f

Re: [FFmpeg-devel] [PATCH v11 07/14] avcodec/vaapi_encode: extract the init and close function to base layer

2024-05-26 Thread Lynne via ffmpeg-devel
On 27/05/2024 02:35, Wu, Tong1 wrote: From: ffmpeg-devel On Behalf Of Lynne via ffmpeg-devel Sent: Saturday, May 25, 2024 10:07 PM To: ffmpeg-devel@ffmpeg.org Cc: Lynne Subject: Re: [FFmpeg-devel] [PATCH v11 07/14] avcodec/vaapi_encode: extract the init and close function to base layer On 25/0

Re: [FFmpeg-devel] [PATCH v11 07/14] avcodec/vaapi_encode: extract the init and close function to base layer

2024-05-26 Thread Wu, Tong1
>From: ffmpeg-devel On Behalf Of Lynne >via ffmpeg-devel >Sent: Saturday, May 25, 2024 10:07 PM >To: ffmpeg-devel@ffmpeg.org >Cc: Lynne >Subject: Re: [FFmpeg-devel] [PATCH v11 07/14] avcodec/vaapi_encode: extract >the init and close function to base layer > >On 25/05/2024 12:30, tong1.wu-at-intel

Re: [FFmpeg-devel] [PATCH 01/17] avcodec/dxva2: Initialize dxva_size and check it

2024-05-26 Thread Michael Niedermayer
On Mon, May 27, 2024 at 01:52:13AM +0200, Michael Niedermayer wrote: > Fixes: CID1591878 Uninitialized scalar variable > Fixes: CID1591928 Uninitialized pointer read > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavcodec/dxva2.c | 4 ++-- > 1 file changed,

[FFmpeg-devel] [PATCH 17/17] avdevice/dshow_filter: Use wcscpy_s()

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591929 Copy into fixed size buffer Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow_filter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavdevice/dshow_filter.c b/libavdevice/dshow_filter.c index 4642ac077c5..2122c84

[FFmpeg-devel] [PATCH 10/17] avdevice/dshow: Remove NULL check on pin

2024-05-26 Thread Michael Niedermayer
The pointer is used before the check Fixes: CID1591884 Dereference before null check Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c ind

[FFmpeg-devel] [PATCH 16/17] avdevice/dshow: Initialize 2 pointers

2024-05-26 Thread Michael Niedermayer
Coverity claims these are used uninitilaized in CID1598561 Uninitialized pointer write and CID1598565 Uninitialized pointer write Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/

[FFmpeg-devel] [PATCH 15/17] avdevice/dshow: check ff_dshow_pin_ConnectionMediaType() for failure

2024-05-26 Thread Michael Niedermayer
Maybe Fixes: CID1598557 Explicit null dereferenced Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index 645c33ea2e6..403e56fe135 100644

[FFmpeg-devel] [PATCH 09/17] avcodec/vp8: Check cond init

2024-05-26 Thread Michael Niedermayer
Fixes: CID1598563 Unchecked return value Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/vp8.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/vp8.c b/libavcodec/vp8.c index 3e1f67172ae..d6df018655c 100644 --- a/libavcodec/v

[FFmpeg-devel] [PATCH 14/17] avdevice/dshow: Cleanup also on av_log case

2024-05-26 Thread Michael Niedermayer
Fixes: CID1598550 Resource leak Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index 557cf33161e..645c33ea2e6 100644 --- a/libavdevice/dshow

[FFmpeg-devel] [PATCH 08/17] avcodec/vp8: Check mutex init

2024-05-26 Thread Michael Niedermayer
Fixes: CID1598556 Unchecked return value Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/vp8.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/vp8.c b/libavcodec/vp8.c index 8e91613068a..3e1f67172ae 100644 --- a/libavcodec/v

[FFmpeg-devel] [PATCH 13/17] avdevice/dshow: Check ICaptureGraphBuilder2_SetFiltergraph() for failure

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591939 Logically dead code Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index 911b0ecc078..557cf33161e 100644 --- a/libavdevice

[FFmpeg-devel] [PATCH 07/17] qsv: Initialize impl_value

2024-05-26 Thread Michael Niedermayer
Fixes: The warnings from CID1598553 Uninitialized scalar variable Passing partly initialized structs is ugly and asking for hard to reproduce bugs, I do not know if this actually fixes a bug or just avoids the uninitialized fields Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niederm

[FFmpeg-devel] [PATCH 12/17] avdevice/dshow: Check device_filter_unique_name before use

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591931 Explicit null dereferenced Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index fd9027b1787..911b0ecc078 100644 --- a/liba

[FFmpeg-devel] [PATCH 06/17] avcodec/mfenc: check IMFSample_ConvertToContiguousBuffer() for failure

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591911 Logically dead code Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/mfenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/mfenc.c b/libavcodec/mfenc.c index 2c68adbdc73..b8f8a25f434 100644 --- a/libavcodec/mfe

[FFmpeg-devel] [PATCH 11/17] avdevice/dshow: fix badly indented line

2024-05-26 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- libavdevice/dshow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c index 8942c0c499a..fd9027b1787 100644 --- a/libavdevice/dshow.c +++ b/libavdevice/dshow.c @@ -1370,7 +1370,7 @@ dshow_open_devic

[FFmpeg-devel] [PATCH 05/17] avcodec/dxva2_*: Initialize dxva_data_ptr

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591888 Uninitialized scalar variable Fixes: CID1591925 Uninitialized pointer read Fixes: CID1591933 Uninitialized scalar variable Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/dxva2_av1.c | 4 ++-- libavcodec/dxva2_hevc.c | 5 - libavcodec/

[FFmpeg-devel] [PATCH 04/17] avcodec/dxva2: initialize hr in ff_dxva2_common_end_frame()

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591924 Uninitialized scalar variable Fixes: CID1591938 Uninitialized scalar variable Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/dxva2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c

[FFmpeg-devel] [PATCH 03/17] avcodec/dxva2: initialize validate

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591915 Uninitialized scalar variable Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/dxva2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c index 550369ba51f..1a33c8bbac7 100644 --- a/liba

[FFmpeg-devel] [PATCH 02/17] avcodec/dxva2: Initialize ConfigBitstreamRaw

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591894 Uninitialized scalar variable Fixes: CID1591906 Uninitialized scalar variable Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/dxva2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c

[FFmpeg-devel] [PATCH 01/17] avcodec/dxva2: Initialize dxva_size and check it

2024-05-26 Thread Michael Niedermayer
Fixes: CID1591878 Uninitialized scalar variable Fixes: CID1591928 Uninitialized pointer read Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavcodec/dxva2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c

Re: [FFmpeg-devel] [PATCH v2] avformat/hls: update current segment reference before use

2024-05-26 Thread J. Dekker
Kacper Michajłow writes: > It may be invalidated by the time it is used. > > Fixes use after free when accessing current segment. > > Fixes: #10825 > Signed-off-by: Kacper Michajłow > --- > libavformat/hls.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/libavformat/hls.c b/libavfo

Re: [FFmpeg-devel] [PATCH v3 01/10] channel_layout: add new channel positions supported by xHE-AAC

2024-05-26 Thread Lynne via ffmpeg-devel
On 26/05/2024 22:51, Marton Balint wrote: On Sun, 26 May 2024, Lynne via ffmpeg-devel wrote: On 25/05/2024 08:10, Marton Balint wrote:  On Sat, 25 May 2024, Lynne via ffmpeg-devel wrote:  apichanges will be updated upon merging, as well as a version bump.  ---  libavutil/channel_layout.h

[FFmpeg-devel] [PATCH v4 01/10] channel_layout: add new channel positions supported by xHE-AAC

2024-05-26 Thread Lynne via ffmpeg-devel
apichanges will be updated upon merging, as well as a version bump. --- libavutil/channel_layout.c | 4 libavutil/channel_layout.h | 8 2 files changed, 12 insertions(+) diff --git a/libavutil/channel_layout.c b/libavutil/channel_layout.c index 98839b7250..2d6963b6df 100644 --- a/li

[FFmpeg-devel] [PATCH v4] fate: add tests for xHE-AAC

2024-05-26 Thread Lynne via ffmpeg-devel
Starting off small with a few features. Samples and reference decoded files copied from the official ISO reference suite. FATE files: https://files.lynne.ee/xhe_refs/ --- tests/fate/aac.mak | 8 1 file changed, 8 insertions(+) diff --git a/tests/fate/aac.mak b/tests/fate/aac.mak index 8

Re: [FFmpeg-devel] [PATCH v3 01/10] channel_layout: add new channel positions supported by xHE-AAC

2024-05-26 Thread Marton Balint
On Sun, 26 May 2024, Lynne via ffmpeg-devel wrote: On 25/05/2024 08:10, Marton Balint wrote: On Sat, 25 May 2024, Lynne via ffmpeg-devel wrote: apichanges will be updated upon merging, as well as a version bump. --- libavutil/channel_layout.h | 4 1 file changed, 4 insertions(+)

Re: [FFmpeg-devel] [PATCH] checkasm/lpc: test compute_autocorr

2024-05-26 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 14.58.53 EEST Rémi Denis-Courmont a écrit : > -- > Change since previous version: > - Disable test on x86, since the x86 optimisation fails > with a suspiciously large and regular error with 10-20% probability. > --- > tests/checkasm/lpc.c | 54

Re: [FFmpeg-devel] [PATCH v2] lpc: rewrite lpc_compute_autocorr in external asm

2024-05-26 Thread Michael Niedermayer
On Sun, May 26, 2024 at 03:42:01AM +0200, Lynne via ffmpeg-devel wrote: > The inline asm function had issues running under checkasm. > So I came to finish what I started, and wrote the last part > of LPC computation in assembly. > --- > libavcodec/x86/lpc.asm| 91 ++

Re: [FFmpeg-devel] [PATCH v3 01/10] channel_layout: add new channel positions supported by xHE-AAC

2024-05-26 Thread Lynne via ffmpeg-devel
On 25/05/2024 08:10, Marton Balint wrote: On Sat, 25 May 2024, Lynne via ffmpeg-devel wrote: apichanges will be updated upon merging, as well as a version bump. --- libavutil/channel_layout.h | 4 1 file changed, 4 insertions(+) diff --git a/libavutil/channel_layout.h b/libavutil/channel

Re: [FFmpeg-devel] [PATCH 01/12] avutil/avassert: Add av_unreachable and av_assume() macros

2024-05-26 Thread Michael Niedermayer
Hi On Sun, May 26, 2024 at 02:59:35AM +0200, Andreas Rheinhardt wrote: > Michael Niedermayer: > > Hi > > > > On Fri, May 24, 2024 at 11:58:21PM +0200, Andreas Rheinhardt wrote: > >> Useful to let the compiler and static analyzers know that > >> something is unreachable without adding an av_assert

Re: [FFmpeg-devel] [PATCH 1/2] libavfilter/signature_lookup: fix possible division by zero

2024-05-26 Thread Michael Niedermayer
On Sun, May 26, 2024 at 05:08:09PM +0200, Gerion Entrup wrote: > Am Freitag, 24. Mai 2024, 23:03:37 MESZ schrieb Michael Niedermayer: > > On Fri, May 24, 2024 at 12:33:11PM +0200, Gerion Entrup wrote: > > > Am Dienstag, 7. Mai 2024, 19:46:28 MESZ schrieb Michael Niedermayer: > > > > On Mon, May 06,

Re: [FFmpeg-devel] [PATCH 1/2] libavfilter/signature_lookup: fix possible division by zero

2024-05-26 Thread Gerion Entrup
Am Freitag, 24. Mai 2024, 23:03:37 MESZ schrieb Michael Niedermayer: > On Fri, May 24, 2024 at 12:33:11PM +0200, Gerion Entrup wrote: > > Am Dienstag, 7. Mai 2024, 19:46:28 MESZ schrieb Michael Niedermayer: > > > On Mon, May 06, 2024 at 12:30:39AM +0200, Gerion Entrup wrote: > > > > --- > > > > li

Re: [FFmpeg-devel] [PATCH v2 2/5] lavc/vp9dsp: R-V V mc bilin h v

2024-05-26 Thread Rémi Denis-Courmont
Le tiistaina 21. toukokuuta 2024, 21.36.33 EEST flow gg a écrit : > Do macros definition also need a comma? Indeed not. I'd rather be safe than sorry though. -- レミ・デニ-クールモン http://www.remlab.net/ ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org ht

Re: [FFmpeg-devel] [PATCH v2 1/5] lavc/vp9dsp: R-V V mc avg

2024-05-26 Thread Rémi Denis-Courmont
Le sunnuntaina 26. toukokuuta 2024, 15.27.55 EEST flow gg a écrit : > Hi, maybe we can prioritize this revert: > https://git.ffmpeg.org/gitweb/ffmpeg.git/commit/0c1304ae11b0361ede055ee8ffc6 > e83529468c73 Using [PATCH v2 1/5] lavc/vp9dsp: R-V V mc avg to avoid > conflicts with other patches. You c

Re: [FFmpeg-devel] [PATCH] checkasm: add h263dsp.{h,v}_loop_filter

2024-05-26 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 19.30.44 EEST James Almer a écrit : > On 5/18/2024 3:44 PM, Rémi Denis-Courmont wrote: > > --- > > > > tests/checkasm/Makefile | 1 + > > tests/checkasm/checkasm.c | 3 ++ > > tests/checkasm/checkasm.h | 1 + > > tests/checkasm/h263dsp.c | 62 +

Re: [FFmpeg-devel] [PATCH v2 1/5] lavc/vp9dsp: R-V V mc avg

2024-05-26 Thread flow gg
Hi, maybe we can prioritize this revert: https://git.ffmpeg.org/gitweb/ffmpeg.git/commit/0c1304ae11b0361ede055ee8ffc6e83529468c73 Using [PATCH v2 1/5] lavc/vp9dsp: R-V V mc avg to avoid conflicts with other patches. flow gg 于2024年5月24日周五 14:13写道: > I want to update the VP9 bilin load, just like

[FFmpeg-devel] [PATCH] lavc/vp8dsp: disable EPEL HV on RV128

2024-05-26 Thread Rémi Denis-Courmont
RV128 is mostly scifi at this point, so we can just disable it here (the EPEL HV prologue/epilogue do not save 128-bit registers). --- libavcodec/riscv/vp8dsp_init.c | 3 ++- libavcodec/riscv/vp8dsp_rvv.S | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/libavcodec/riscv/vp8ds

Re: [FFmpeg-devel] [PATCH v4 1/4] doc: Explain what "context" means

2024-05-26 Thread Andrew Sayers
It feels like we've got through most of the mid-level "how FFmpeg works" stuff, and now we're left with language choices (e.g "options" vs. "introspection") and philosophical discussions (e.g. the relationship between contexts and OOP). It's probably best to philosophise first, then come back to la

Re: [FFmpeg-devel] [PATCH] configure: enable ffnvcodec, nvenc, nvdec for FreeBSD

2024-05-26 Thread Timo Rothenpieler
On 26.05.2024 07:22, Brad Smith wrote: On 2024-05-19 7:24 a.m., Timo Rothenpieler wrote: On 19.05.2024 02:00, Brad Smith wrote: configure: enable ffnvcodec, nvenc, nvdec for FreeBSD Signed-off-by: Brad Smith ---   configure | 2 +-   1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/

[FFmpeg-devel] [PATCH 3/3] lavc/vp7dsp: R-V V vp7_idct_add

2024-05-26 Thread Rémi Denis-Courmont
Most of the code is shared with DC, thanks to minor earlier changes. vp7_idct_add_c: 5.2 vp7_idct_add_rvv_i32: 2.5 --- libavcodec/riscv/vp7dsp_init.c | 2 ++ libavcodec/riscv/vp7dsp_rvv.S | 29 + 2 files changed, 31 insertions(+) diff --git a/libavcodec/riscv/

[FFmpeg-devel] [PATCH 2/3] lavc/vp7dsp: revector ff_vp7_dc_wht_rvv

2024-05-26 Thread Rémi Denis-Courmont
This prepares for some code reuse. --- libavcodec/riscv/vp7dsp_init.c | 3 ++- libavcodec/riscv/vp7dsp_rvv.S | 23 ++- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/libavcodec/riscv/vp7dsp_init.c b/libavcodec/riscv/vp7dsp_init.c index 5a57a39d0b..1406eb1c6a

[FFmpeg-devel] [PATCH] lavc/vp7dsp: add R-V V vp7_luma_dc_wht

2024-05-26 Thread Rémi Denis-Courmont
This works out a bit more favourably than VP8's due to: - additional multiplications that can be vectored, - hardware-supported fixed-point rounding mode. vp7_luma_dc_wht_c: 3.2 vp7_luma_dc_wht_rvv_i64: 2.0 --- libavcodec/riscv/Makefile | 2 + libavcodec/riscv/vp7dsp_init.c | 41 +

[FFmpeg-devel] [PATCH] lavc/vvc: Validate temporal MVP references

2024-05-26 Thread Frank Plowman
Per VVCv3 p. 157, the collocated reference picture used in temporal motion vector prediction must have RprConstraintsActiveFlag equal to zero and the same CTU size as the current picture. Add these checks, fixing crashes decoding some fuzzed bitstreams. Additionally, only set up the collocated re

Re: [FFmpeg-devel] [PATCH] lavc/vp8dsp: R-V V vp8_luma_dc_wht

2024-05-26 Thread Rémi Denis-Courmont
Le sunnuntaina 26. toukokuuta 2024, 10.29.02 EEST Rémi Denis-Courmont a écrit : > diff --git a/libavcodec/riscv/vp8dsp_init.c b/libavcodec/riscv/vp8dsp_init.c > index 2413fbf449..d48fe08560 100644 > --- a/libavcodec/riscv/vp8dsp_init.c > +++ b/libavcodec/riscv/vp8dsp_init.c > @@ -26,6 +26,7 @@ >

[FFmpeg-devel] [PATCH] lavc/vp8dsp: R-V V vp8_luma_dc_wht

2024-05-26 Thread Rémi Denis-Courmont
This is not great as transposition is poorly supported, but it works: vp8_luma_dc_wht_c: 2.5 vp8_luma_dc_wht_rvv_i32: 1.7 --- libavcodec/riscv/vp8dsp_init.c | 2 ++ libavcodec/riscv/vp8dsp_rvv.S | 55 ++ 2 files changed, 57 insertions(+) diff --git a/libavc