[FFmpeg-devel] [PATCH 1/3] avcodec: [loongarch] Optimize hpeldsp with LASX.

2021-12-24 Thread Hao Chen
From: Shiyou Yin ./ffmpeg -i 8_mpeg4_1080p_24fps_12Mbps.avi -f rawvideo -y /dev/null -an before:376fps after :433fps Change-Id: Ic8018562093154887323b508b81d0f489c0d265d Signed-off-by: Hao Chen --- libavcodec/hpeldsp.c |2 + libavcodec/hpeldsp.h

[FFmpeg-devel] [PATCH 3/3] avcodec: [loongarch] Optimize prefetch with loongarch.

2021-12-24 Thread Hao Chen
From: gxw ./ffmpeg -i ../1_h264_1080p_30fps_3Mbps.mp4 -f rawvideo -y /dev/null -an before:296 after :308 Change-Id: I748490c1551d0ecfb8b8001625cf7e4e30f28eb4 --- libavcodec/loongarch/Makefile| 1 + libavcodec/loongarch/videodsp_init.c | 45 libavcodec/video

Re: [FFmpeg-devel] [PATCH V3 2/2] libavutil/hwcontext_opencl: fix a bug for mapping qsv frame to opencl

2021-12-26 Thread Chen, Wenbin
> On Fri, 2021-12-10 at 13:38 +0800, Wenbin Chen wrote: > > From: nyanmisaka > > > > mfxHDLPair was added to qsv, so modify qsv->opencl map function as well. > > Now the following commandline works: > > > > ffmpeg -v verbose -init_hw_device vaapi=va:/de

Re: [FFmpeg-devel] [PATCH 1/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2021-12-26 Thread Chen, Wenbin
> On Wed, 2021-10-27 at 16:57 +0800, Wenbin Chen wrote: > > Fix: #7706. After commit 5fdcf85bbffe7451c2, vaapi encoder's performance > > decrease. The reason is that vaRenderPicture() and vaSyncSurface() are > > called at the same time (vaRenderPicture() always follo

Re: [FFmpeg-devel] [PATCH 1/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2021-12-27 Thread Chen, Wenbin
> On 27/10/2021 09:57, Wenbin Chen wrote: > > Fix: #7706. After commit 5fdcf85bbffe7451c2, vaapi encoder's performance > > decrease. The reason is that vaRenderPicture() and vaSyncSurface() are > > called at the same time (vaRenderPicture() always followed by a > >

Re: [FFmpeg-devel] [FFmpeg-cvslog] libavutil/hwcontext_vaapi: Add a new nv12 format map to support vulkan frame

2021-12-27 Thread Chen, Wenbin
> On 10/12/2021 16:05, Wenbin Chen wrote: > > ffmpeg | branch: master | Wenbin Chen | Tue > Dec 7 17:05:50 2021 +0800| [f3c9847c2754b7a43eb721c95e356a53085c2491] > | committer: Lynne > > > > libavutil/hwcontext_vaapi: Add a new nv12 format map to support vulkan >

[FFmpeg-devel] [PATCH v2 3/3] avcodec: [loongarch] Optimize prefetch with loongarch.

2021-12-29 Thread Hao Chen
From: gxw ./ffmpeg -i ../1_h264_1080p_30fps_3Mbps.mp4 -f rawvideo -y /dev/null -an before:296 after :308 --- libavcodec/loongarch/Makefile| 1 + libavcodec/loongarch/videodsp_init.c | 45 libavcodec/videodsp.c| 2 ++ libavcodec/videodsp.h

[FFmpeg-devel] [PATCH v2 2/3] avcodec: [loongarch] Optimize idctdstp with LASX.

2021-12-29 Thread Hao Chen
@ -0,0 +1,45 @@ +/* + * Copyright (c) 2021 Loongson Technology Corporation Limited + * Contributed by Hao Chen + * + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published

[FFmpeg-devel] Optimize Mpeg4 decoding for loongarch

2021-12-29 Thread Hao Chen
./ffmpeg -i 8_mpeg4_1080p_24fps_12Mbps.avi -f rawvideo -y /dev/null -an before:376fps after :552fps V2: Revised PATCH 1/3 according to the comments. V3: Resubmit these patches due to miss PATCH v2 1/3. [PATCH v3 1/3] avcodec: [loongarch] Optimize hpeldsp with LASX. [PATCH v3 2/3] avcodec: [loonga

[FFmpeg-devel] [PATCH v3 1/3] avcodec: [loongarch] Optimize hpeldsp with LASX.

2021-12-29 Thread Hao Chen
From: Shiyou Yin ./ffmpeg -i 8_mpeg4_1080p_24fps_12Mbps.avi -f rawvideo -y /dev/null -an before:376fps after :433fps --- libavcodec/hpeldsp.c |2 + libavcodec/hpeldsp.h |1 + libavcodec/loongarch/Makefile |2 + libavco

[FFmpeg-devel] [PATCH v3 2/3] avcodec: [loongarch] Optimize idctdstp with LASX.

2021-12-29 Thread Hao Chen
@ -0,0 +1,45 @@ +/* + * Copyright (c) 2021 Loongson Technology Corporation Limited + * Contributed by Hao Chen + * + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published

[FFmpeg-devel] [PATCH v3 3/3] avcodec: [loongarch] Optimize prefetch with loongarch.

2021-12-29 Thread Hao Chen
From: gxw ./ffmpeg -i ../1_h264_1080p_30fps_3Mbps.mp4 -f rawvideo -y /dev/null -an before:296 after :308 --- libavcodec/loongarch/Makefile| 1 + libavcodec/loongarch/videodsp_init.c | 45 libavcodec/videodsp.c| 2 ++ libavcodec/videodsp.h

[FFmpeg-devel] [PATCH] doc/encoders.texi Add doc for qsv

2022-01-04 Thread Wenbin Chen
Add doc for qsv decoder. Add more option's introduction to qsv encoder. Signed-off-by: Wenbin Chen --- doc/decoders.texi | 42 doc/encoders.texi | 253 +- 2 files changed, 292 insertions(+), 3 deletions(-) diff --git a/doc/decoders.t

[FFmpeg-devel] [PATCH V2 1/3] libavcodec/vaapi_encode: Add new API adaption to vaapi_encode

2022-01-04 Thread Wenbin Chen
. "wait=1" means wait until operation ready. "wait=0" means query operation's status. If it is ready return 0, if it is still in progress return EAGAIN. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 47 +-- 1 file changed, 40 i

[FFmpeg-devel] [PATCH V2 2/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2022-01-04 Thread Wenbin Chen
uffer, it will keep previous operation. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 64 --- libavcodec/vaapi_encode.h | 5 +++ 2 files changed, 58 insertions(+), 11 deletions(-) diff --git a/libavcodec/vaapi_encode.c b/libavcodec/vaapi_encode.c

[FFmpeg-devel] [PATCH V2 3/3] libavcodec/vaapi_encode: Add async_depth to vaapi_encoder to increase performance

2022-01-04 Thread Wenbin Chen
es) with -async_depth=4 can increase 20% performance on my environment. The async increases performance but also introduces frame delay. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 19 ++- libavcodec/vaapi_encode.h | 12 ++-- 2 files changed, 24 insertio

Re: [FFmpeg-devel] [PATCH V2 2/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2022-01-04 Thread Chen, Wenbin
> Wenbin Chen: > > Fix: #7706. After commit 5fdcf85bbffe7451c2, vaapi encoder's performance > > decrease. The reason is that vaRenderPicture() and vaSyncBuffer() are > > called at the same time (vaRenderPicture() always followed by a > > vaSyncBuffer()). When we

[FFmpeg-devel] [PATCH V2] doc/encoders.texi: Add doc for qsv

2022-01-05 Thread Wenbin Chen
Add doc for qsv decoder. Add more option's introduction to qsv encoder. Signed-off-by: Wenbin Chen --- doc/decoders.texi | 42 doc/encoders.texi | 253 +- 2 files changed, 292 insertions(+), 3 deletions(-) diff --git a/doc/decoders.t

[FFmpeg-devel] [PATCH V4 1/2] libavcodec/vaapi_decode: fix the problem that init_pool_size < nb_surface

2022-01-06 Thread Wenbin Chen
ces). Now add code to make sure init_pool_size is only set once. Now the following commandline works: ffmpeg -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 \ -hwaccel_output_format vaapi -i input.264 \ -vf "hwmap=derive_device=qsv,format=qsv" \ -c:v h264_qsv output.264 Signed-off-by

[FFmpeg-devel] [PATCH V4 2/2] libavutil/hwcontext_opencl: fix a bug for mapping qsv frame to opencl

2022-01-06 Thread Wenbin Chen
qsv -hwaccel_output_format qsv -hwaccel_device qs -c:v h264_qsv \ -i input.264 -vf "hwmap=derive_device=opencl,format=opencl,avgblur_opencl, \ hwmap=derive_device=qsv:reverse=1:extra_hw_frames=32,format=qsv" \ -c:v h264_qsv output.264 Signed-off-by: nyanmisaka Signed-off-by: Wenbin Chen -

Re: [FFmpeg-devel] [PATCH V4 2/2] libavutil/hwcontext_opencl: fix a bug for mapping qsv frame to opencl

2022-01-10 Thread Chen, Wenbin
> On Fri, 2022-01-07 at 15:36 +0800, Wenbin Chen wrote: > > From: nyanmisaka > > > > mfxHDLPair was added to qsv, so modify qsv->opencl map function as well. > > Now the following commandline works: > > > > ffmpeg -v verbose -init_hw_device vaapi=va:/de

[FFmpeg-devel] [PATCH V5 1/2] libavcodec/vaapi_decode: fix the problem that init_pool_size < nb_surface

2022-01-10 Thread Wenbin Chen
ces). Now add code to make sure init_pool_size is only set once. Now the following commandline works: ffmpeg -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 \ -hwaccel_output_format vaapi -i input.264 \ -vf "hwmap=derive_device=qsv,format=qsv" \ -c:v h264_qsv output.264 Signed-off-by

[FFmpeg-devel] [PATCH V5 2/2] libavutil/hwcontext_opencl: fix a bug for mapping qsv frame to opencl

2022-01-10 Thread Wenbin Chen
qsv -hwaccel_output_format qsv -hwaccel_device qs -c:v h264_qsv \ -i input.264 -vf "hwmap=derive_device=opencl,format=opencl,avgblur_opencl, \ hwmap=derive_device=qsv:reverse=1:extra_hw_frames=32,format=qsv" \ -c:v h264_qsv output.264 Signed-off-by: nyanmisaka Signed-off-by: Wenbin Chen -

[FFmpeg-devel] [PATCH V2] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-11 Thread Wenbin Chen
Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can disable deblocking. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 8 libavcodec/qsvenc.h | 3 +++ 3 files changed, 17 insertions(+) diff --git a/doc/encoders.texi b/doc

[FFmpeg-devel] [PATCH V2] libavcodec/qsvenc: Add low latency P-pyramid support to qsv

2022-01-11 Thread Wenbin Chen
github.com/Intel-Media-SDK/MediaSDK/blob/master/doc/mediasdk-man.md#preftype Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 36 libavcodec/qsvenc.h | 3 +++ 3 files changed, 45 insertions(+) diff --git a/doc/encoders.t

[FFmpeg-devel] [PATCH V2] libavcodec/qsvenc: Add max_frame_size support to hevc_qsv

2022-01-11 Thread Wenbin Chen
Add max_frame_size support to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index 7cc8be1209..68921fbd40 100644 --- a/doc

[FFmpeg-devel] [PATCH V2] libavcodec/qsvenc: Add transform skip to hevc_qsv

2022-01-11 Thread Wenbin Chen
Add transform_skip option to hevc_qsv. By enabling this option, the transform_skip_enabled_flag in PPS will be set to 1. This option is only supported in the platform newer than ICL. Signed-off-by: Wenbin Chen --- doc/encoders.texi| 3 +++ libavcodec/qsvenc.c | 10

Re: [FFmpeg-devel] [PATCH V2] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-12 Thread Chen, Wenbin
> On Wed, 2022-01-12 at 13:28 +0800, Wenbin Chen wrote: > > Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can > > disable deblocking. > > > > Signed-off-by: Wenbin Chen > > --- > > doc/encoders.texi | 6 ++ > > libavcodec/q

[FFmpeg-devel] [PATCH V3 1/4] libavcodec/qsvenc: Add max_frame_size support to hevc_qsv

2022-01-12 Thread Wenbin Chen
Add max_frame_size support to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index 7cc8be1209..68921fbd40 100644 --- a/doc

[FFmpeg-devel] [PATCH V3 2/4] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-12 Thread Wenbin Chen
Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can disable deblocking. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 8 libavcodec/qsvenc.h | 3 +++ 3 files changed, 17 insertions(+) diff --git a/doc/encoders.texi b/doc

[FFmpeg-devel] [PATCH V3 3/4] libavcodec/qsvenc: Add low latency P-pyramid support to qsv

2022-01-12 Thread Wenbin Chen
github.com/Intel-Media-SDK/MediaSDK/blob/master/doc/mediasdk-man.md#preftype Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 36 libavcodec/qsvenc.h | 3 +++ 3 files changed, 45 insertions(+) diff --git a/doc/encoders.t

[FFmpeg-devel] [PATCH V3 4/4] libavcodec/qsvenc: Add transform skip to hevc_qsv

2022-01-12 Thread Wenbin Chen
Add transform_skip option to hevc_qsv. By enabling this option, the transform_skip_enabled_flag in PPS will be set to 1. This option is supported on the platform equal or newer than CNL. Signed-off-by: Wenbin Chen --- doc/encoders.texi| 4 libavcodec/qsvenc.c | 10

[FFmpeg-devel] [PATCH V4 4/4] libavcodec/qsvenc: Add transform skip to hevc_qsv

2022-01-12 Thread Wenbin Chen
Add transform_skip option to hevc_qsv. By enabling this option, the transform_skip_enabled_flag in PPS will be set to 1. This option is supported on the platform equal or newer than ICL. Signed-off-by: Wenbin Chen --- doc/encoders.texi| 4 libavcodec/qsvenc.c | 10

[FFmpeg-devel] [PATCH V4 1/4] libavcodec/qsvenc: Add max_frame_size support to hevc_qsv

2022-01-12 Thread Wenbin Chen
Add max_frame_size support to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index 7cc8be1209..68921fbd40 100644 --- a/doc

[FFmpeg-devel] [PATCH V4 2/4] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-12 Thread Wenbin Chen
Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can disable deblocking. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 8 libavcodec/qsvenc.h | 3 +++ 3 files changed, 17 insertions(+) diff --git a/doc/encoders.texi b/doc

[FFmpeg-devel] [PATCH V4 3/4] libavcodec/qsvenc: Add low latency P-pyramid support to qsv

2022-01-12 Thread Wenbin Chen
github.com/Intel-Media-SDK/MediaSDK/blob/master/doc/mediasdk-man.md#preftype Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 36 libavcodec/qsvenc.h | 3 +++ 3 files changed, 45 insertions(+) diff --git a/doc/encoders.t

Re: [FFmpeg-devel] [PATCH V3 2/4] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-13 Thread Chen, Wenbin
> On Thu, 2022-01-13 at 13:12 +0800, Wenbin Chen wrote: > > Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can > > disable deblocking. > > > > Signed-off-by: Wenbin Chen > > --- > > doc/encoders.texi | 6 ++ > > libavcodec/q

Re: [FFmpeg-devel] [PATCH V3 4/4] libavcodec/qsvenc: Add transform skip to hevc_qsv

2022-01-13 Thread Chen, Wenbin
> On Thu, 2022-01-13 at 13:12 +0800, Wenbin Chen wrote: > > Add transform_skip option to hevc_qsv. By enabling this option, > > the transform_skip_enabled_flag in PPS will be set to 1. > > This option is supported on the platform equal or newer than CNL. > > >

[FFmpeg-devel] [PATCH V5 1/4] libavcodec/qsvenc: Add max_frame_size support to hevc_qsv

2022-01-16 Thread Wenbin Chen
Add max_frame_size support to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index 7cc8be1209..68921fbd40 100644 --- a/doc

[FFmpeg-devel] [PATCH V5 2/4] libavcodec/qsvenc: Add DisableDeblockingIdc support to qsv

2022-01-16 Thread Wenbin Chen
Add dblk_idc option to 264_qsv and hevc_qsv. Turining on this opion can disable deblocking. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 7 +++ libavcodec/qsvenc.h | 3 +++ 3 files changed, 16 insertions(+) diff --git a/doc/encoders.texi b/doc

[FFmpeg-devel] [PATCH V5 3/4] libavcodec/qsvenc: Add low latency P-pyramid support to qsv

2022-01-16 Thread Wenbin Chen
github.com/Intel-Media-SDK/MediaSDK/blob/master/doc/mediasdk-man.md#preftype Signed-off-by: Wenbin Chen --- doc/encoders.texi | 6 ++ libavcodec/qsvenc.c | 36 libavcodec/qsvenc.h | 3 +++ 3 files changed, 45 insertions(+) diff --git a/doc/encoders.t

[FFmpeg-devel] [PATCH V5 4/4] libavcodec/qsvenc: Add transform skip to hevc_qsv

2022-01-16 Thread Wenbin Chen
Add transform_skip option to hevc_qsv. By enabling this option, the transform_skip_enabled_flag in PPS will be set to 1. This option is supported on the platform equal or newer than ICL. Signed-off-by: Wenbin Chen --- doc/encoders.texi| 4 libavcodec/qsvenc.c | 13

Re: [FFmpeg-devel] [PATCH 1/3] swscale: don't assign range converters for float

2024-01-10 Thread Chen, Wenbin
> On Mon, 27 Nov 2023 02:10:11 +0000 "Chen, Wenbin" intel@ffmpeg.org> wrote: > > > > From: Niklas Haas > > > > > > > > This logic was incongruent with logic used elsewhere, where floating > > > > point formats are explici

[FFmpeg-devel] [PATCH v2 0/1] avfilter/vf_vpp_qsv: apply 3D LUT from file

2024-01-20 Thread Chen Yufei
Note: requires oneVPL-intel-gpu version >= 24.1.1 because this version contains a fix for creating LUT in video memory. (For details, refer to https://github.com/oneapi-src/oneVPL-intel-gpu/issues/307) Chen Yufei (1): avfilter/vf_vpp_qsv: apply 3D LUT from file. libavfilter/Makefile

[FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-20 Thread Chen Yufei
Usage: "vpp_qsv=lut3d_file=" Requires oneVPL, using system memory 3D LUT surface. Signed-off-by: Chen Yufei --- libavfilter/Makefile | 8 +- libavfilter/lut3d.c | 669 +++ libavfilter/lut3d.h | 13 + libavfilter/vf_lut3d

Re: [FFmpeg-devel] [PATCH v2 0/1] avfilter/vf_vpp_qsv: apply 3D LUT from file

2024-01-23 Thread Chen Yufei
On Tue, Jan 23, 2024 at 10:00 AM Xiang, Haihao wrote: > > On Sa, 2024-01-20 at 23:14 +0800, Chen Yufei wrote: > > This patch adds support for applying 3D LUT from file using oneVPL VPP. > > > > PATCH v1 uses VA-API to create LUT surface. Because oneVPL can't work wit

Re: [FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-25 Thread Chen Yufei
On Wed, Jan 24, 2024 at 7:39 PM Anton Khirnov wrote: > > Quoting Chen Yufei (2024-01-20 16:14:29) > > Usage: "vpp_qsv=lut3d_file=" > > Passing file paths to a filter and having the filter load the file is > not recommended, it is generally preferable to have an &g

[FFmpeg-devel] [PATCH v3 0/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-27 Thread Chen Yufei
This version of PATCH use `QSV_RUNTIME_VERSION_ATLEAST` to apply 3D LUT when libvpl runtime API version >= 2.11. Chen Yufei (1): avfilter/vf_vpp_qsv: apply 3D LUT from file. libavfilter/Makefile | 8 +- libavfilter/lut3d.c | 669 +++ libavfil

[FFmpeg-devel] [PATCH v3 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-27 Thread Chen Yufei
Usage: "vpp_qsv=lut3d_file=" Requires oneVPL, using system memory 3D LUT surface. Signed-off-by: Chen Yufei --- libavfilter/Makefile | 8 +- libavfilter/lut3d.c | 669 +++ libavfilter/lut3d.h | 13 + libavfilter/vf_lut3d

Re: [FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-28 Thread Chen Yufei
On Sun, Jan 28, 2024 at 10:10 PM Anton Khirnov wrote: > > Quoting Zhao Zhili (2024-01-28 14:51:58) > > > > > > > On Jan 28, 2024, at 18:31, Anton Khirnov wrote: > > > > > > Quoting Chen Yufei (2024-01-25 17:16:46) > > >

Re: [FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-29 Thread Chen Yufei
file name extension to detect LUT file type and call different parse functions. If we add another option to specify LUT file type, then vf_lut3d's command line option would require change. -- Best regards, Chen Yufei ___ ffmpeg-devel mailing lis

Re: [FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-01-29 Thread Chen Yufei
On Tue, Jan 30, 2024 at 1:07 AM Anton Khirnov wrote: > > Quoting Chen Yufei (2024-01-29 04:01:51) > > On Sun, Jan 28, 2024 at 10:10 PM Anton Khirnov wrote: > > > > > > Quoting Zhao Zhili (2024-01-28 14:51:58) > > > > > > > > >

Re: [FFmpeg-devel] [PATCH v2 1/1] avfilter/vf_vpp_qsv: apply 3D LUT from file.

2024-02-03 Thread Chen Yufei
On Tue, Jan 30, 2024 at 10:59 AM Chen Yufei wrote: > > On Tue, Jan 30, 2024 at 1:07 AM Anton Khirnov wrote: > > > > Quoting Chen Yufei (2024-01-29 04:01:51) > > > On Sun, Jan 28, 2024 at 10:10 PM Anton Khirnov wrote: > > > > > >

[FFmpeg-devel] [PATCH 01/10] libavfilter/vulkan: Fix problem when device have queue_count greater than 1

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" If the descriptorSetCount is greater than the number of setLayouts, vkAllocateDescriptorSets will report error. Now fix it. Now the following command can run on the device that has queue_count greater than one: ffmpeg -v verbose -init_hw_device vulkan=vul:0 -filter

[FFmpeg-devel] [PATCH 02/10] libavutil/hwcontext_vulkan: fix a tile mismatch problem

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" We should configure VkImageSubresource according to tiling rather than extension. We use extension to set tiling only when we map from drm. Normally the output VkImages are not created in this way, and it will report error when we map these VkImage to drm, so

[FFmpeg-devel] [PATCH 03/10] libavfilter/vulkan: Fix the way to use sem

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" We chould set waitSem and signalSem differently. Current ffmpeg-vulkan uses the same sem to set waitSem and signalSem and it doesn't work on latest intel-vulkan-driver. The commit: a193060221c4df123e26a562949cae5df3e73cde on mesa causes this problem. This com

[FFmpeg-devel] [PATCH 04/10] hwcontext_vaapi: Use PRIME_2 memory type for modifiers.

2021-08-30 Thread wenbin . chen
From: Bas Nieuwenhuizen This way we can pass explicit modifiers in. Sometimes the modifier matters for the number of memory planes that libva accepts, in particular when dealing with driver-compressed textures. Furthermore the driver might not actually be able to determine the implicit modifier i

[FFmpeg-devel] [PATCH 05/10] libavutil/hwcontext_vaapi: Add a new nv12 format map to support vulkan frame

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" Vulkan will map nv12 to R8 and GR88, so add this map to vaapi to support vulkan frame. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vaapi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavutil/hwcontext_vaapi.c b/libavutil/hwcontext_vaapi.c index

[FFmpeg-devel] [PATCH 06/10] libavutil/hwcontext_vulkan: Add one_memory flag to make vulkan compatible with vaapi device.

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" Vaapi can import external surface, but all the planes of the external frames should be in the same drm object. A new flag is introduced and vulkan can choose to allocate planes in one memory according this flag. This flag will be enabled when the vulkan device is de

[FFmpeg-devel] [PATCH 08/10] libavutil/hwcontext_vulkan: fix wrong offset of plane

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" According to spec, if we use VkBindImagePlaneMemoryInfo to bind image we mush create image with disjoint flag. The offset in subresourcelayout is relative to the base address of the plane, but the offset in drm is relative to the drm objectis so I think this offset

[FFmpeg-devel] [PATCH 07/10] libavutil/hwcontext_vulkan: Allocate vkFrame in one memory

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" The vaapi can import external frame, but the planes of the external frames should be in the same drm object. I add a new function to allocate vkFrame in one memory and vulkan device will choose a way to allocate memory according to one_memory flag. A new variable i

[FFmpeg-devel] [PATCH 09/10] libavutil/hwcontext_vulkan: specify the modifier to create VKImage

2021-08-30 Thread wenbin . chen
From: Wenbin Chen On the lastset intel-vulkan-driver the VK_EXT_image_drm_format_modifier flags is enabled. As what driver log recommand, we need to use VK_IMAGE_TILING_LINEAR or VK_IMAGE_DRM_FORMAT_MODIFIER_EXT to create VKImage. Add code to get supported modifier for sw_format and use these

[FFmpeg-devel] [PATCH 10/10] libavutil/hwcontext_vulkan: Add hwupload and hwdownload support when using one_memory flag.

2021-08-30 Thread wenbin . chen
From: "Chen,Wenbin" Add hwupload and hwdownload support to vulkan when frames are allocated in one memory Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/libavutil/hwcontext_vulkan.c b

Re: [FFmpeg-devel] [PATCH 01/10] libavfilter/vulkan: Fix problem when device have queue_count greater than 1

2021-08-30 Thread Chen, Wenbin
e queue_count greater than 1 > > Hello, > > On Tue, 31 Aug 2021, at 03:43, wenbin.c...@intel.com wrote: > > From: "Chen,Wenbin" > > ... > > Signed-off-by: Wenbin Chen > > ... > > email sent by "wenbin.c...@intel.com" (no name) >

[FFmpeg-devel] [V2 01/10] libavfilter/vulkan: Fix problem when device have queue_count greater than 1

2021-08-31 Thread Wenbin Chen
-vf "hwupload=extra_hw_frames=16,scale_vulkan=1920:1080, hwdownload,format=yuv420p" -f rawvideo output.yuv Signed-off-by: Wenbin Chen --- libavfilter/vulkan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavfilter/vulkan.c b/libavfilter/vulkan.c index

[FFmpeg-devel] [V2 02/10] libavutil/hwcontext_vulkan: fix a tile mismatch problem

2021-08-31 Thread Wenbin Chen
according to tiling rather than extension. Now fix it. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c index 94fdad7f06..88db5b8b70 100644 --- a/libavutil

[FFmpeg-devel] [V2 03/10] libavfilter/vulkan: Fix the way to use sem

2021-08-31 Thread Wenbin Chen
t;hwupload=extra_hw_frames=16,scale_vulkan=1920:1080, hwdownload,format=yuv420p" -f rawvideo output.yuv Signed-off-by: Wenbin Chen --- libavfilter/vf_avgblur_vulkan.c | 4 +-- libavfilter/vf_chromaber_vulkan.c | 4 +-- libavfilter/vf_overlay_vulkan.c | 6 ++-- libavfilter/vf_scale_vu

[FFmpeg-devel] [V2 04/10] hwcontext_vaapi: Use PRIME_2 memory type for modifiers.

2021-08-31 Thread Wenbin Chen
From: Bas Nieuwenhuizen This way we can pass explicit modifiers in. Sometimes the modifier matters for the number of memory planes that libva accepts, in particular when dealing with driver-compressed textures. Furthermore the driver might not actually be able to determine the implicit modifier i

[FFmpeg-devel] [V2 05/10] libavutil/hwcontext_vaapi: Add a new nv12 format map to support vulkan frame

2021-08-31 Thread Wenbin Chen
Vulkan will map nv12 to R8 and GR88, so add this map to vaapi to support vulkan frame. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vaapi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavutil/hwcontext_vaapi.c b/libavutil/hwcontext_vaapi.c index 75acc851d6..994b744e4d 100644

[FFmpeg-devel] [V2 06/10] libavutil/hwcontext_vulkan: Add one_memory flag to make vulkan compatible with vaapi device.

2021-08-31 Thread Wenbin Chen
this change will not affect current vulkan behaviour. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c index 9a29267aed..6417f59d4a 100644 --- a

[FFmpeg-devel] [V2 07/10] libavutil/hwcontext_vulkan: Allocate vkFrame in one memory

2021-08-31 Thread Wenbin Chen
offset of each plane. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 46 +++- libavutil/hwcontext_vulkan.h | 1 + 2 files changed, 46 insertions(+), 1 deletion(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c index

[FFmpeg-devel] [V2 09/10] libavutil/hwcontext_vulkan: specify the modifier to create VKImage

2021-08-31 Thread Wenbin Chen
64 Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 77 +--- libavutil/hwcontext_vulkan.h | 5 +++ 2 files changed, 76 insertions(+), 6 deletions(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c index 3a639c997b..99b2190dc3 10

[FFmpeg-devel] [V2 10/10] libavutil/hwcontext_vulkan: Add hwupload and hwdownload support when using one_memory flag.

2021-08-31 Thread Wenbin Chen
Add hwupload and hwdownload support to vulkan when frames are allocated in one memory Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulkan.c index

[FFmpeg-devel] [V2 08/10] libavutil/hwcontext_vulkan: fix wrong offset of plane

2021-08-31 Thread Wenbin Chen
vaapi frame to vulkan I got broken frame, and setting plane_data->offset to 0 makes command works. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_vulkan.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libavutil/hwcontext_vulkan.c b/libavutil/hwcontext_vulka

Re: [FFmpeg-devel] [V2 08/10] libavutil/hwcontext_vulkan: fix wrong offset of plane

2021-08-31 Thread Chen, Wenbin
but the offset in drm is relative to the drm objectis so > > I think this offset should be 0. > > Also, when I import vaapi frame to vulkan I got broken frame, and > > setting plane_data->offset to 0 makes command works. > > > > Signed-off-by: Wenbin Chen > &g

Re: [FFmpeg-devel] [V2 03/10] libavfilter/vulkan: Fix the way to use sem

2021-08-31 Thread Chen, Wenbin
esa on intel platform: > > ffmpeg -v verbose -init_hw_device vulkan=vul:0,linear_images=1 - > filter_hw_device vul > > -i input1080p.264 -vf > "hwupload=extra_hw_frames=16,scale_vulkan=1920:1080, > > hwdownload,format=yuv420p" -f rawvideo output.yuv > > > > Signed

Re: [FFmpeg-devel] [V2 08/10] libavutil/hwcontext_vulkan: fix wrong offset of plane

2021-09-05 Thread Chen, Wenbin
> -Original Message- > From: Lynne > Sent: Wednesday, September 1, 2021 7:33 PM > To: Chen, Wenbin > Subject: RE: [FFmpeg-devel] [V2 08/10] libavutil/hwcontext_vulkan: fix wrong > offset of plane > > 1 Sept 2021, 03:40 by wenbin.c...@intel.com: > > &g

Re: [FFmpeg-devel] [PATCH v2] avutils/hwcontext: When deriving a hwdevice, search for existing device in both directions

2021-09-07 Thread Chen, Wenbin
Hi softworkz: Any updates on this patch? I want to submit pathes to qsv, but they depends on this patch Thanks Wenbin > -Original Message- > From: ffmpeg-devel On Behalf Of Soft > Works > Sent: Thursday, August 19, 2021 3:52 PM > To: FFmpeg development discussions and patches de...@ffmp

Re: [FFmpeg-devel] [PATCH v2] avutils/hwcontext: When deriving a hwdevice, search for existing device in both directions

2021-09-08 Thread Chen, Wenbin
gt; hwdevice, search for existing device in both directions > > > > > -Original Message- > > From: ffmpeg-devel On Behalf Of > > Chen, Wenbin > > Sent: Wednesday, 8 September 2021 07:58 > > To: FFmpeg development discussions and patches > de...@ffmpeg

[FFmpeg-devel] [PATCH] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-09 Thread Wenbin Chen
a[3] in vaapi frame. pair->first is *VASurfaceID while data[3] in vaapi frame is VASurfaceID. I fix this line of code. Now the command above works. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_qsv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/hwcontext_q

Re: [FFmpeg-devel] [PATCH] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-09 Thread Chen, Wenbin
> -Original Message- > From: ffmpeg-devel On Behalf Of > James Almer > Sent: Thursday, September 9, 2021 8:48 PM > To: ffmpeg-devel@ffmpeg.org > Subject: Re: [FFmpeg-devel] [PATCH] libavutil/hwcontext_qsv: fix a bug for > mapping qsv frame to vaapi > > On 9/

Re: [FFmpeg-devel] [PATCH] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-12 Thread Chen, Wenbin
> On Fri, 2021-09-10 at 02:19 +0000, Chen, Wenbin wrote: > > > -Original Message- > > > From: ffmpeg-devel On Behalf Of > > > James Almer > > > Sent: Thursday, September 9, 2021 8:48 PM > > > To: ffmpeg-devel@ffmpeg.org > > > Su

[FFmpeg-devel] [PATCH V2] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-12 Thread Wenbin Chen
a[3] in vaapi frame. pair->first is *VASurfaceID while data[3] in vaapi frame is VASurfaceID. I fix this line of code. Now the command above works. Signed-off-by: Wenbin Chen --- libavutil/hwcontext_qsv.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavutil/h

Re: [FFmpeg-devel] [PATCH V2] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-14 Thread Chen, Wenbin
Assign pair->first directly to data[3] in vaapi frame. > pair->first is *VASurfaceID while data[3] in vaapi frame is > VASurfaceID. I fix this line of code. Now the command above works. > > Signed-off-by: Wenbin Chen > --- > libavutil/hwcontext_qsv.c | 6 +- > 1 file

[FFmpeg-devel] [PATCH] libavfilter/vf_vpp_qsv: fix uninitialized variable problem

2021-09-14 Thread Wenbin Chen
This two variables may be used below with uninitialized value. Now fix them. Signed-off-by: Wenbin Chen --- libavfilter/vf_vpp_qsv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavfilter/vf_vpp_qsv.c b/libavfilter/vf_vpp_qsv.c index c268b5dba8..22ffe0d7f3 100644

Re: [FFmpeg-devel] [PATCH V2] libavutil/hwcontext_qsv: fix a bug for mapping qsv frame to vaapi

2021-09-23 Thread Chen, Wenbin
Assign pair->first directly to data[3] in vaapi frame. > pair->first is *VASurfaceID while data[3] in vaapi frame is > VASurfaceID. I fix this line of code. Now the command above works. > > Signed-off-by: Wenbin Chen > --- > libavutil/hwcontext_qsv.c | 6 +- > 1 file

[FFmpeg-devel] [PATCH] libavcodec/qsvenc: fix a memory leak problem

2022-01-19 Thread Wenbin Chen
"qf->frame" ref to input frame but it isn't released. av_frame_unref() is added before refering qf->frame to new frame to make sure the previous reference is released. Signed-off-by: Wenbin Chen --- libavcodec/qsvenc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/

Re: [FFmpeg-devel] [PATCH V5 2/2] libavutil/hwcontext_opencl: fix a bug for mapping qsv frame to opencl

2022-01-19 Thread Chen, Wenbin
put.264 > > Signed-off-by: nyanmisaka > Signed-off-by: Wenbin Chen > --- > libavutil/hwcontext_opencl.c | 14 +- > libavutil/hwcontext_qsv.c| 34 ++ > 2 files changed, 47 insertions(+), 1 deletion(-) > > diff --gi

Re: [FFmpeg-devel] [PATCH V5 1/2] libavcodec/vaapi_decode: fix the problem that init_pool_size < nb_surface

2022-01-19 Thread Chen, Wenbin
evice=qsv,format=qsv" \ > -c:v h264_qsv output.264 > > Signed-off-by: Wenbin Chen > --- > libavcodec/vaapi_decode.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/vaapi_decode.c b/libavcodec/vaapi_decode.c > index 665af370ed..da0

[FFmpeg-devel] [PATCH 1/3] libavcodec/qsvenc: Add max slice size support to hevc_qsv

2022-01-23 Thread Wenbin Chen
Add max_slice_size option to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 9 - 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index e3adbf4325..8966610263 100644 --- a/doc

[FFmpeg-devel] [PATCH 2/3] libavcodec/qsvenc: Add b_strategy option to hevc_qsv

2022-01-23 Thread Wenbin Chen
Add b_strategy option to hevc_qsv. By enabling this option, encoder can use b frames as reference. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 6 -- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi

[FFmpeg-devel] [PATCH 3/3] libavcodec/qsvenc: Add intra refresh to hevc_qsv and add new intra refresh parameter

2022-01-23 Thread Wenbin Chen
Add intra refresh support to hevc_qsv as well. Add an new intra refresh type: "horizontal", and an new param ref_cycle_dist. This param specify the distance between the beginnings of the intra-refresh cycles in frames. Signed-off-by: Wenbin Chen --- doc/encoders.texi

Re: [FFmpeg-devel] [PATCH 3/3] libavcodec/qsvenc: Add intra refresh to hevc_qsv and add new intra refresh parameter

2022-01-24 Thread Chen, Wenbin
> On Mon, 2022-01-24 at 10:59 +0800, Wenbin Chen wrote: > > Add intra refresh support to hevc_qsv as well. > > Add an new intra refresh type: "horizontal", and an new param > > ref_cycle_dist. This param specify the distance between the > > beginnings

[FFmpeg-devel] [PATCH V2 2/3] libavcodec/qsvenc: Add b_strategy option to hevc_qsv

2022-01-24 Thread Wenbin Chen
Add b_strategy option to hevc_qsv. By enabling this option, encoder can use b frames as reference. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 6 -- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi

[FFmpeg-devel] [PATCH V2 1/3] libavcodec/qsvenc: Add max slice size support to hevc_qsv

2022-01-24 Thread Wenbin Chen
Add max_slice_size option to hevc_qsv as well. Signed-off-by: Wenbin Chen --- doc/encoders.texi | 3 +++ libavcodec/qsvenc.c | 9 - 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index e3adbf4325..8966610263 100644 --- a/doc

[FFmpeg-devel] [PATCH V2 3/3] libavcodec/qsvenc: Add intra refresh to hevc_qsv and add new intra refresh parameter

2022-01-24 Thread Wenbin Chen
Add intra refresh support to hevc_qsv as well. Add an new intra refresh type: "horizontal", and an new param ref_cycle_dist. This param specify the distance between the beginnings of the intra-refresh cycles in frames. Signed-off-by: Wenbin Chen --- doc/encoders.texi

Re: [FFmpeg-devel] [PATCH V2 2/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2022-02-06 Thread Chen, Wenbin
> On Wed, 2022-01-05 at 10:48 +0800, Wenbin Chen wrote: > > Fix: #7706. After commit 5fdcf85bbffe7451c2, vaapi encoder's performance > > decrease. The reason is that vaRenderPicture() and vaSyncBuffer() are > > called at the same time (vaRenderPicture() always foll

[FFmpeg-devel] [PATCH V3 1/3] libavcodec/vaapi_encode: Add new API adaption to vaapi_encode

2022-02-07 Thread Wenbin Chen
. "wait=1" means wait until operation ready. "wait=0" means query operation's status. If it is ready return 0, if it is still in progress return EAGAIN. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 47 +-- 1 file changed, 40 i

[FFmpeg-devel] [PATCH V3 2/3] libavcodec/vaapi_encode: Change the way to call async to increase performance

2022-02-07 Thread Wenbin Chen
uffer, it will keep previous operation. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 64 --- libavcodec/vaapi_encode.h | 5 +++ 2 files changed, 58 insertions(+), 11 deletions(-) diff --git a/libavcodec/vaapi_encode.c b/libavcodec/vaapi_encode.c

[FFmpeg-devel] [PATCH V3 3/3] libavcodec/vaapi_encode: Add async_depth to vaapi_encoder to increase performance

2022-02-07 Thread Wenbin Chen
es) with -async_depth=4 can increase 20% performance on my environment. The async increases performance but also introduces frame delay. Signed-off-by: Wenbin Chen --- libavcodec/vaapi_encode.c | 16 libavcodec/vaapi_encode.h | 12 ++-- 2 files changed, 22 insertio

<    1   2   3   4   5   6   >