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

2024-05-25 Thread Rémi Denis-Courmont
Le sunnuntaina 26. toukokuuta 2024, 1.31.18 EEST James Almer a écrit : > On 5/25/2024 5:57 PM, 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. > > > > au

[FFmpeg-devel] [PATCH] lavc/lpc: optimise RVV vector type for compute_autocorr

2024-05-25 Thread Rémi Denis-Courmont
On SpacemiT X60 (with len == 4000): autocorr_10_c: 2303.7 autocorr_10_rvv_f64: 1411.5 (before) autocorr_10_rvv_f64: 842.2 (after) --- libavcodec/riscv/lpc_init.c | 3 ++- libavcodec/riscv/lpc_rvv.S | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/libavcodec/riscv/l

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

2024-05-25 Thread Brad Smith
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/configure b/configure index b16722d83d..

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

2024-05-25 Thread James Almer
On 5/25/2024 10:51 PM, James Almer wrote: On 5/25/2024 10:42 PM, 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 v2] lpc: rewrite lpc_compute_autocorr in external asm

2024-05-25 Thread James Almer
On 5/25/2024 10:42 PM, 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 +++ libavcodec/x86

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

2024-05-25 Thread Lynne via ffmpeg-devel
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 +++ libavcodec/x86/lpc_init.c | 87 - 2

Re: [FFmpeg-devel] [PATCH] web/contact: relink code of conduct

2024-05-25 Thread Michael Niedermayer
On Fri, May 24, 2024 at 07:36:07PM +0200, Michael Niedermayer wrote: > Found-by: John Hawkinson > > Signed-off-by: Michael Niedermayer > --- > src/contact | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) will apply [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611

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

2024-05-25 Thread Andreas Rheinhardt
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 >> (which would be either dead for the compiler or add runtime >> overhead) for thi

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

2024-05-25 Thread James Almer
On 5/25/2024 5:57 PM, 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. autocorr_10_c: 135525.8 autocorr_10_sse2: 50729.8 autocorr_10_fma3: 19007.8 autocorr_30_c: 39

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

2024-05-25 Thread 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 > (which would be either dead for the compiler or add runtime > overhead) for this. > > Signed-off-by: Andreas

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

2024-05-25 Thread James Almer
On 5/25/2024 9:02 PM, Lynne via ffmpeg-devel wrote: On 26/05/2024 00:45, James Almer wrote: On 5/25/2024 7:31 PM, James Almer wrote: On 5/25/2024 5:57 PM, 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

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

2024-05-25 Thread Lynne via ffmpeg-devel
On 26/05/2024 00:45, James Almer wrote: On 5/25/2024 7:31 PM, James Almer wrote: On 5/25/2024 5:57 PM, 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. autocorr_1

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

2024-05-25 Thread James Almer
On 5/25/2024 8:24 PM, Lynne via ffmpeg-devel wrote: On 26/05/2024 00:31, James Almer wrote: On 5/25/2024 5:57 PM, 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.

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

2024-05-25 Thread Lynne via ffmpeg-devel
On 26/05/2024 00:31, James Almer wrote: On 5/25/2024 5:57 PM, 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. autocorr_10_c: 135525.8 autocorr_10_sse2: 50729.8 au

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

2024-05-25 Thread James Almer
On 5/25/2024 7:31 PM, James Almer wrote: On 5/25/2024 5:57 PM, 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. autocorr_10_c: 135525.8 autocorr_10_sse2: 50729.8 a

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

2024-05-25 Thread James Almer
On 5/25/2024 5:57 PM, 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. autocorr_10_c: 135525.8 autocorr_10_sse2: 50729.8 autocorr_10_fma3: 19007.8 autocorr_30_c: 39

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

2024-05-25 Thread Michael Niedermayer
On Sat, May 25, 2024 at 10:57:21PM +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. > > autocorr_10_c: 135525.8 > autocorr_10_sse2: 50729.8 > autocorr_10

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

2024-05-25 Thread Lynne via ffmpeg-devel
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. autocorr_10_c: 135525.8 autocorr_10_sse2: 50729.8 autocorr_10_fma3: 19007.8 autocorr_30_c: 390100.8 autocorr_30_sse2: 142478.8 autocorr_30_fma3: 50

Re: [FFmpeg-devel] [RFC PATCH] all: Adapt BSD license headers to avoid fate-source exceptions

2024-05-25 Thread Pierre-Anthony Lemieux
On Sat, May 25, 2024 at 7:57 AM Andreas Rheinhardt wrote: > > Andreas Rheinhardt: > > This is against the 80 char line length limit, but it is not > > a hard rule anyway. > > > > Signed-off-by: Andreas Rheinhardt > > --- > > This is an alternative to modifying check-source.sh (for which I also >

Re: [FFmpeg-devel] [RFC PATCH 2/2] tests/fate/source-check: Relax BSD licence check

2024-05-25 Thread Pierre-Anthony Lemieux
On Wed, May 22, 2024 at 4:38 AM Andreas Rheinhardt wrote: > > Several files already had standard license header (namely > 2-clause BSD files), yet due to the 80 char line length limit, > they were not treated as such by source-check.sh (which > fate-source uses). Therefore relax the BSD check. LG

Re: [FFmpeg-devel] [PATCH v2 1/5] fftools/ffmpeg_demux: honor -ch_layout options for overriding input stream channel layout

2024-05-25 Thread Anton Khirnov
Quoting Marton Balint (2024-05-25 18:57:32) > > > On Sun, 19 May 2024, Marton Balint wrote: > > > The code only set the channel layout of the AVFormatContext, so the user > > could > > not override the channel layout if the demuxer did not have such parameter. > > > > This used to work via the

Re: [FFmpeg-devel] [PATCH 5/5] lavc/vp8dsp: factor R-V V EPEL functions for all lengths

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 21.56.58 EEST flow gg a écrit : > The reduction in code size seems to be due to switching to using j labels, > doesn't seem to be about vset, but another issue. j labels are indeed > better. I will make similar modifications. If we don't use vsetvl, then we have

[FFmpeg-devel] [PATCH] lavc/sbrdsp: add support for 256-bit vectors

2024-05-25 Thread Rémi Denis-Courmont
hf_apply_noise_0_c: 35.7 hf_apply_noise_0_rvv_f32: 9.5 hf_apply_noise_1_c: 38.5 hf_apply_noise_1_rvv_f32: 10.0 hf_apply_noise_2_c: 35.5 hf_apply_noise_2_rvv_f32: 9.7 hf_apply_noise_3_c: 38.5 hf_apply_noise_3_rvv_f32: 10.0 Maybe extending the noise table manually is not such great idea, but I not q

[FFmpeg-devel] [PATCH] lavc/sbrdsp: fix potential overflow in noise table

2024-05-25 Thread Rémi Denis-Courmont
Since the SBR noise application optimisations are currently restricted to hardware with 128-bit vectors, and use a quadruple multipler, they can load up to 16 32-bit elements. But the "loads" are of 2 segments, or 16 pairs of single precision float. Thus we need to expand the dupiclated section of

Re: [FFmpeg-devel] [PATCH 5/5] lavc/vp8dsp: factor R-V V EPEL functions for all lengths

2024-05-25 Thread flow gg
Well, I'm mainly considering that we have added some vset related lines, but they haven't played a new role for the time being. If it's for future modifications, it does make sense. > This is reducing code size by over 2 kib of code, or several hundreds of instructions. The reduction in code size

Re: [FFmpeg-devel] [PATCH 5/5] lavc/vp8dsp: factor R-V V EPEL functions for all lengths

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 21.16.22 EEST flow gg a écrit : > Would it be better to replace the two vsetvlstatic8 and vsetvlstatic16 with > two vsetvl? The other option is to hard-code the most pessimistic multiplier. That would be easier to read and save two instructions in the head, it w

Re: [FFmpeg-devel] [PATCH 5/5] lavc/vp8dsp: factor R-V V EPEL functions for all lengths

2024-05-25 Thread flow gg
Would it be better to replace the two vsetvlstatic8 and vsetvlstatic16 with two vsetvl? This would require the previous patch and this one to work together, increasing the number of lines of code and making the code a bit harder to read. Additionally, I have a question about patch 4 'save one R-V G

Re: [FFmpeg-devel] [PATCH] lavc/sbrdsp: fix inverted boundary check

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 20.52.44 EEST Rémi Denis-Courmont a écrit : > 128-it is the maximum, not the minimum here. Larger vector sizes can > result in reads past the end of the noise value table. Nit: bit > > This partially reverts commit cdcb4b98b7f74d87a6274899ff70724795d551cb. > --

[FFmpeg-devel] [PATCH] lavc/sbrdsp: fix inverted boundary check

2024-05-25 Thread Rémi Denis-Courmont
128-it is the maximum, not the minimum here. Larger vector sizes can result in reads past the end of the noise value table. This partially reverts commit cdcb4b98b7f74d87a6274899ff70724795d551cb. --- libavcodec/riscv/sbrdsp_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[FFmpeg-devel] [PATCH] lavc/sbrdsp: fold immediate offset into relocation

2024-05-25 Thread Rémi Denis-Courmont
This results in AUIPC; ADDI instead of AUIPC; ADDI; ... ADDI. --- libavcodec/riscv/sbrdsp_rvv.S | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libavcodec/riscv/sbrdsp_rvv.S b/libavcodec/riscv/sbrdsp_rvv.S index aba9a28108..331b88022c 100644 --- a/libavcodec/riscv/sbrdsp_rvv.

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

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 13.38.39 EEST flow gg a écrit : > > Is there a reason that you cannot use the tables from C code? > > Similar to VP8, to adjust the positive and negative data and prevent small > probability overflow during calculations. > > > AFAICT, regular and sharp are ident

Re: [FFmpeg-devel] [PATCH v2 1/5] fftools/ffmpeg_demux: honor -ch_layout options for overriding input stream channel layout

2024-05-25 Thread Marton Balint
On Sun, 19 May 2024, Marton Balint wrote: The code only set the channel layout of the AVFormatContext, so the user could not override the channel layout if the demuxer did not have such parameter. This used to work via the respective AVCodecContext option, but since 639c2f00497257cb60ecaeeac

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

2024-05-25 Thread James Almer
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 +++ tests/fate/checkasm.mak | 1 + 5 files changed, 68 insertio

[FFmpeg-devel] [PATCH] avdovi/dovi_rpu{enc, dec}: fix ms_weight handling

2024-05-25 Thread Niklas Haas
From: Niklas Haas The code as written was wrong. The l2.ms_weight value is coded as a *signed* integer, rather than a shifted unsigned integer. (And even so, the offset of 8192 would be too large, since 2^12 = 4096. Ditto for l8.ms_weight, which should have an offset of 2048, not 8192) In additi

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

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 18. toukokuuta 2024, 21.44.10 EEST Rémi Denis-Courmont a écrit : > --- > tests/checkasm/Makefile | 1 + > tests/checkasm/checkasm.c | 3 ++ > tests/checkasm/checkasm.h | 1 + > tests/checkasm/h263dsp.c | 62 +++ > tests/fate/checkasm.mak |

[FFmpeg-devel] [PATCH 5/5] lavc/vp8dsp: factor R-V V EPEL functions for all lengths

2024-05-25 Thread Rémi Denis-Courmont
--- libavcodec/riscv/vp8dsp_rvv.S | 56 --- 1 file changed, 32 insertions(+), 24 deletions(-) diff --git a/libavcodec/riscv/vp8dsp_rvv.S b/libavcodec/riscv/vp8dsp_rvv.S index a4fcd158a5..002e7f3174 100644 --- a/libavcodec/riscv/vp8dsp_rvv.S +++ b/libavcodec/riscv/v

[FFmpeg-devel] [PATCH 3/5] lavc/vp8dsp: factor R-V V bilin functions

2024-05-25 Thread Rémi Denis-Courmont
For a given type, only the first VSETVLI instruction varies depending on the size. --- libavcodec/riscv/vp8dsp_rvv.S | 37 +-- 1 file changed, 27 insertions(+), 10 deletions(-) diff --git a/libavcodec/riscv/vp8dsp_rvv.S b/libavcodec/riscv/vp8dsp_rvv.S index bb0c7bf

[FFmpeg-devel] [PATCH 4/5] lavc/vp8dsp: save one R-V GPR

2024-05-25 Thread Rémi Denis-Courmont
This saves one instruction and frees up A5, which will be repurposed in later changes. Unfortunately, we need to add quite a lot of alternative code for this. --- libavcodec/riscv/vp8dsp_rvv.S | 24 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/libavcodec/

[FFmpeg-devel] [PATCH 1/5] lavc/vp8dsp: avoid one multiplication on RISC-V

2024-05-25 Thread Rémi Denis-Courmont
Use shifts rather than multiply, and save one instruction. --- libavcodec/riscv/vp8dsp_init.c | 26 ++ libavcodec/riscv/vp8dsp_rvv.S | 7 +++ 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/libavcodec/riscv/vp8dsp_init.c b/libavcodec/riscv/vp8dsp_init

[FFmpeg-devel] [PATCH 2/5] lavc/vp8dsp: expand single use R-V macros

2024-05-25 Thread Rémi Denis-Courmont
--- libavcodec/riscv/vp8dsp_rvv.S | 24 ++-- 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/libavcodec/riscv/vp8dsp_rvv.S b/libavcodec/riscv/vp8dsp_rvv.S index cb9b0b8b5f..bb0c7bf02a 100644 --- a/libavcodec/riscv/vp8dsp_rvv.S +++ b/libavcodec/riscv/vp8dsp_rvv.S

Re: [FFmpeg-devel] [RFC PATCH] all: Adapt BSD license headers to avoid fate-source exceptions

2024-05-25 Thread Andreas Rheinhardt
Andreas Rheinhardt: > This is against the 80 char line length limit, but it is not > a hard rule anyway. > > Signed-off-by: Andreas Rheinhardt > --- > This is an alternative to modifying check-source.sh (for which I also > sent a patch). > > doc/mips.txt | 5 ++--- >

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

2024-05-25 Thread Lynne via ffmpeg-devel
On 25/05/2024 16:18, Sean McGovern wrote: Hi, On Sat, May 25, 2024, 09:07 Lynne via ffmpeg-devel wrote: On 25/05/2024 12:30, tong1.wu-at-intel@ffmpeg.org wrote: From: Tong Wu Related parameters such as device context, frame context are also moved to base layer. Signed-off-by: Tong Wu

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

2024-05-25 Thread Sean McGovern
Hi, On Sat, May 25, 2024, 09:07 Lynne via ffmpeg-devel wrote: > On 25/05/2024 12:30, tong1.wu-at-intel@ffmpeg.org wrote: > > From: Tong Wu > > > > Related parameters such as device context, frame context are also moved > > to base layer. > > > > Signed-off-by: Tong Wu > > --- > > libavc

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

2024-05-25 Thread James Almer
On 5/25/2024 8:58 AM, Rémi Denis-Courmont wrote: -- Change since previous version: - Disable test on x86, since the x86 optimisation fails with a suspiciously large and regular error with 10-20% probability. Weird. The sse2 function is written using inline gcc, so it's pretty old. And it se

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

2024-05-25 Thread Lynne via ffmpeg-devel
On 25/05/2024 12:30, tong1.wu-at-intel@ffmpeg.org wrote: From: Tong Wu Related parameters such as device context, frame context are also moved to base layer. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 49 ++ libavcodec/hw_base_encode.h | 17 +++

Re: [FFmpeg-devel] [PATCH 3/3] avformat/hlsenc: Remove dead ret stores

2024-05-25 Thread Steven Liu
Michael Niedermayer 于2024年5月25日周六 19:18写道: > > Fixes: CID1529222 Unused value > > Sponsored-by: Sovereign Tech Fund > Signed-off-by: Michael Niedermayer > --- > libavformat/hlsenc.c | 4 > 1 file changed, 4 deletions(-) > > diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c > index 0

Re: [FFmpeg-devel] [PATCH 1/3] avformat/file: check for lseek() failure

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 15.19.51 EEST Michael Niedermayer a écrit : > On Sat, May 25, 2024 at 02:38:07PM +0300, Rémi Denis-Courmont wrote: > > Le lauantaina 25. toukokuuta 2024, 14.18.12 EEST Michael Niedermayer a écrit : > > > Fixes: CID1559855 Unchecked return value from library > >

Re: [FFmpeg-devel] [PATCH 1/3] avformat/file: check for lseek() failure

2024-05-25 Thread Michael Niedermayer
On Sat, May 25, 2024 at 02:38:07PM +0300, Rémi Denis-Courmont wrote: > Le lauantaina 25. toukokuuta 2024, 14.18.12 EEST Michael Niedermayer a écrit : > > Fixes: CID1559855 Unchecked return value from library > > This is again very misleading. Logging an error (that most people won't even > see) i

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

2024-05-25 Thread Rémi Denis-Courmont
-- 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 ++-- 1 file changed, 52 insertions(+), 2 deletions(-) diff --git

Re: [FFmpeg-devel] [PATCH] avcodec/h2645_sei: loosen up min luminance requirements

2024-05-25 Thread Kacper Michajlow
On Sat, 25 May 2024 at 13:36, Niklas Haas wrote: > > From: Niklas Haas > > The H.265 specification is quite clear on this case: > > > When min_display_mastering_luminance is not in the range of 1 to > > 5, the nominal maximum display luminance of the mastering display > > is unknown or unspec

Re: [FFmpeg-devel] [PATCH 1/3] avformat/file: check for lseek() failure

2024-05-25 Thread Rémi Denis-Courmont
Le lauantaina 25. toukokuuta 2024, 14.18.12 EEST Michael Niedermayer a écrit : > Fixes: CID1559855 Unchecked return value from library This is again very misleading. Logging an error (that most people won't even see) is not fixing a bug. Either this is not a bug, and this patch can't be fixing a

[FFmpeg-devel] [PATCH] avcodec/h2645_sei: loosen up min luminance requirements

2024-05-25 Thread Niklas Haas
From: Niklas Haas The H.265 specification is quite clear on this case: > When min_display_mastering_luminance is not in the range of 1 to > 5, the nominal maximum display luminance of the mastering display > is unknown or unspecified or specified by other means not specified in > this Specif

[FFmpeg-devel] [PATCH 3/3] avformat/hlsenc: Remove dead ret stores

2024-05-25 Thread Michael Niedermayer
Fixes: CID1529222 Unused value Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavformat/hlsenc.c | 4 1 file changed, 4 deletions(-) diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index 0e2843c6bc5..8a43ef6232a 100644 --- a/libavformat/hlsenc.c +++ b/l

[FFmpeg-devel] [PATCH 2/3] avformat/fwse: Remove always false expression

2024-05-25 Thread Michael Niedermayer
Fixes: CID1460758 Operands don't affect result Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavformat/fwse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/fwse.c b/libavformat/fwse.c index 6c1103da146..dc4750d946a 100644 --- a/libav

[FFmpeg-devel] [PATCH 1/3] avformat/file: check for lseek() failure

2024-05-25 Thread Michael Niedermayer
Fixes: CID1559855 Unchecked return value from library Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavformat/file.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libavformat/file.c b/libavformat/file.c index 0ed4cff266c..e2ef85aa705 10064

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

2024-05-25 Thread Stefano Sabatini
On date Thursday 2024-05-23 21:00:40 +0100, Andrew Sayers wrote: > Derived from explanations kindly provided by Stefano Sabatini and others: > https://ffmpeg.org/pipermail/ffmpeg-devel/2024-April/325903.html > --- > doc/context.md | 439 + > 1 file c

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

2024-05-25 Thread flow gg
One more thing I remember is that after adjusting the sign, vmacc can be used; otherwise, due to the sign, mul + add are needed. flow gg 于2024年5月25日周六 18:38写道: > > Is there a reason that you cannot use the tables from C code? > > Similar to VP8, to adjust the positive and negative data and preve

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

2024-05-25 Thread flow gg
> Is there a reason that you cannot use the tables from C code? Similar to VP8, to adjust the positive and negative data and prevent small probability overflow during calculations. > AFAICT, regular and sharp are identical, except for the base address of the > filter table, so it should be possib

[FFmpeg-devel] [PATCH v11 13/14] avcodec: add D3D12VA hardware HEVC encoder

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu This implementation is based on D3D12 Video Encoding Spec: https://microsoft.github.io/DirectX-Specs/d3d/D3D12VideoEncoding.html Sample command line for transcoding: ffmpeg.exe -hwaccel d3d12va -hwaccel_output_format d3d12 -i input.mp4 -c:v hevc_d3d12va output.mp4 Signed-off-by: T

[FFmpeg-devel] [PATCH v11 14/14] Changelog: add D3D12VA HEVC encoder changelog

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Signed-off-by: Tong Wu --- Changelog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Changelog b/Changelog index 12770e4296..c5d57b3813 100644 --- a/Changelog +++ b/Changelog @@ -11,7 +11,7 @@ version : - vf_scale2ref deprecated - qsv_params option added for

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

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Related parameters such as device context, frame context are also moved to base layer. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 49 ++ libavcodec/hw_base_encode.h | 17 +++ libavcodec/vaapi_encode.c | 90 +++---

[FFmpeg-devel] [PATCH v11 11/14] avcodec/vaapi_encode: extract a free funtion to base layer

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 11 +++ libavcodec/hw_base_encode.h | 2 ++ libavcodec/vaapi_encode.c | 6 +- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/libavcodec/hw_base_encode.c b/libavcodec/hw_base_encode.c index 31

[FFmpeg-devel] [PATCH v11 12/14] avutil/hwcontext_d3d12va: add Flags for resource creation

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Flags field is added to support diffferent resource creation. Signed-off-by: Tong Wu --- doc/APIchanges| 3 +++ libavutil/hwcontext_d3d12va.c | 2 +- libavutil/hwcontext_d3d12va.h | 8 libavutil/version.h | 2 +- 4 files changed, 13 insertions(+

[FFmpeg-devel] [PATCH v11 10/14] avcodec/vaapi_encode: extract a get_recon_format function to base layer

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Surface size and block size parameters are also moved to base layer. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 58 +++ libavcodec/hw_base_encode.h | 12 + libavcodec/vaapi_encode.c | 81 - libavc

[FFmpeg-devel] [PATCH v11 09/14] avcodec/vaapi_encode: extract set_output_property to base layer

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 40 + libavcodec/hw_base_encode.h | 3 +++ libavcodec/vaapi_encode.c | 44 ++--- 3 files changed, 45 insertions(+), 42 deletions(-) diff --git a/libavcodec/

[FFmpeg-devel] [PATCH v11 06/14] avcodec/vaapi_encode: move the dpb logic from VAAPI to base layer

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Move receive_packet function to base. This requires adding *alloc, *issue, *output, *free as hardware callbacks. HWBaseEncodePicture is introduced as the base layer structure. The related parameters in VAAPIEncodeContext are also extracted to HWBaseEncodeContext. Then DPB management

[FFmpeg-devel] [PATCH v11 08/14] avcodec/vaapi_encode: extract gop configuration and two options to base layer

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu idr_interval and desired_b_depth are moved to HW_BASE_ENCODE_COMMON_OPTIONS. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.c | 54 + libavcodec/hw_base_encode.h | 19 + libavcodec/vaapi_encode.c | 52 +++

[FFmpeg-devel] [PATCH v11 05/14] avcodec/vaapi_encode: move pic->input_surface initialization to encode_alloc

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu When allocating the VAAPIEncodePicture, pic->input_surface can be initialized right in the place. This movement simplifies the send_frame logic and is the preparation for moving vaapi_encode_send_frame to the base layer. Signed-off-by: Tong Wu --- libavcodec/vaapi_encode.c | 8 +

[FFmpeg-devel] [PATCH v11 04/14] avcodec/vaapi_encode: add picture type name to base

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.h | 6 ++ libavcodec/vaapi_encode.c | 4 +--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/libavcodec/hw_base_encode.h b/libavcodec/hw_base_encode.h index c14c174102..858450afa8 100644 --- a/libavcodec/hw

[FFmpeg-devel] [PATCH v11 03/14] avcodec/vaapi_encode: add async_depth to common options

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.h | 10 +- libavcodec/vaapi_encode.c | 13 - libavcodec/vaapi_encode.h | 7 --- libavcodec/vaapi_encode_av1.c | 1 + libavcodec/vaapi_encode_h264.c | 1 + libavcodec/vaapi_encode_h26

[FFmpeg-devel] [PATCH v11 02/14] avcodec/hw_base_encode: add FF_HW_ prefix for two enums

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu PICTURE_TYPE_* and FLAG_* are added FF_HW_ prefix after being moved to base layer. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.h | 20 ++--- libavcodec/vaapi_encode.c | 50 - libavcodec/vaapi_encode_av1.c | 12

[FFmpeg-devel] [PATCH v11 01/14] avcodec/vaapi_encode: introduce a base layer for vaapi encode

2024-05-25 Thread tong1 . wu-at-intel . com
From: Tong Wu Since VAAPI and future D3D12VA implementation may share some common parameters, a base layer encode context is introduced as vaapi context's base. Signed-off-by: Tong Wu --- libavcodec/hw_base_encode.h | 56 + libavcodec/vaapi_encode.h | 39 +

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

2024-05-25 Thread Rémi Denis-Courmont
Le tiistaina 21. toukokuuta 2024, 20.13.17 EEST u...@foxmail.com a écrit : > From: sunyuechi > > C908 X60 > vp9_avg_8tap_smooth_4h_8bpp_c : 13.0 11.2 > vp9_avg_8tap_smooth_4h_8bpp_rvv_i32:5.04.

Re: [FFmpeg-devel] [PATCH v5 2/4] lavu: Clarify relationship between AVClass, AVOption and context

2024-05-25 Thread Stefano Sabatini
On date Thursday 2024-05-23 21:00:41 +0100, Andrew Sayers wrote: > --- > libavutil/log.h | 16 +--- > libavutil/opt.h | 17 ++--- > 2 files changed, 27 insertions(+), 6 deletions(-) > > diff --git a/libavutil/log.h b/libavutil/log.h > index ab7ceabe22..d599ab506e 100644 >

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

2024-05-25 Thread Stefano Sabatini
On date Wednesday 2024-05-22 17:07:51 +0100, Andrew Sayers wrote: [...] > > > diff --git a/doc/context.md b/doc/context.md > > > new file mode 100644 > > > index 00..fb85b3f366 > > > --- /dev/null > > > +++ b/doc/context.md > > > @@ -0,0 +1,394 @@ > > > +# Introduction to contexts > > > + >

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

2024-05-25 Thread Stefano Sabatini
On date Wednesday 2024-05-22 13:47:36 +0100, Andrew Sayers wrote: > On Wed, May 22, 2024 at 12:37:37PM +0200, Stefano Sabatini wrote: > > On date Sunday 2024-05-05 22:04:36 +0100, Andrew Sayers wrote: > > > I'm still travelling, so the following thoughts might be a bit > > > half-formed. But I wan

Re: [FFmpeg-devel] [PATCH] lavc/vvc_mc: R-V V avg w_avg

2024-05-25 Thread Rémi Denis-Courmont
Hi, Sorry for the delay, this is not my day job. Le tiistaina 21. toukokuuta 2024, 22.24.21 EEST u...@foxmail.com a écrit : > From: sunyuechi > --- > libavcodec/riscv/Makefile | 2 + > libavcodec/riscv/vvc_mc_rvv.S | 313 + > libavcodec/riscv/vvcd