[FFmpeg-devel] ffmpeg_opt: deprecate the hwaccel_lax_profile_check option

Submitted by Jun Zhao on Oct. 13, 2017, 7:07 a.m.

Details

Message ID eb04d51f-b704-4255-0425-5d4c8baa3883@gmail.com
State New
Headers show

Commit Message

Jun Zhao Oct. 13, 2017, 7:07 a.m.
From 40c45849b5146688ce6f88ca4fe20b771fb2de46 Mon Sep 17 00:00:00 2001
From: Jun Zhao <jun.zhao@intel.com>
Date: Fri, 13 Oct 2017 02:53:01 -0400
Subject: [PATCH] ffmpeg_opt: deprecate the hwaccel_lax_profile_check option

deprecate hwaccel_lax_profile_check. This only was used for VAAPI
hwaccel decoder, now use per-stream hwaccel_flags for all hwaccel
decoders.

Signed-off-by: Jun Zhao <jun.zhao@intel.com>
---
 fftools/ffmpeg_opt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Mark Thompson Oct. 15, 2017, 8:22 p.m.
On 13/10/17 08:07, Jun Zhao wrote:
> From 40c45849b5146688ce6f88ca4fe20b771fb2de46 Mon Sep 17 00:00:00 2001
> From: Jun Zhao <jun.zhao@intel.com>
> Date: Fri, 13 Oct 2017 02:53:01 -0400
> Subject: [PATCH] ffmpeg_opt: deprecate the hwaccel_lax_profile_check option
> 
> deprecate hwaccel_lax_profile_check. This only was used for VAAPI
> hwaccel decoder, now use per-stream hwaccel_flags for all hwaccel
> decoders.
> 
> Signed-off-by: Jun Zhao <jun.zhao@intel.com>
> ---
>  fftools/ffmpeg_opt.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
> index 100fa76e46..f1c96ce08c 100644
> --- a/fftools/ffmpeg_opt.c
> +++ b/fftools/ffmpeg_opt.c
> @@ -100,7 +100,7 @@ const HWAccel hwaccels[] = {
>  #endif
>      { 0 },
>  };
> -int hwaccel_lax_profile_check = 0;
> +attribute_deprecated int hwaccel_lax_profile_check = 0;
>  AVBufferRef *hw_device_ctx;
>  HWDevice *filter_hw_device;
>  
> -- 
> 2.11.0

Having thought about this a bit further and searched for uses, I now agree with your original position that the option should just be removed.  Results in google are /all/ patches to do with it, links to the code, or appearances of the message which was in some versions last year suggesting its use.

I'll apply your original patch for this (<https://lists.ffmpeg.org/pipermail/ffmpeg-devel/2017-October/217670.html>) tomorrow if there are no objections.

Thanks,

- Mark

(Aside: the patch just sent doesn't actually do what you want - it only deprecates the variable and triggers warnings building ffmpeg.c, but doesn't say anything about the option itself at runtime.)
Jun Zhao Oct. 16, 2017, 12:10 a.m.
On 2017/10/16 4:22, Mark Thompson wrote:
> On 13/10/17 08:07, Jun Zhao wrote:
>> From 40c45849b5146688ce6f88ca4fe20b771fb2de46 Mon Sep 17 00:00:00 2001
>> From: Jun Zhao <jun.zhao@intel.com>
>> Date: Fri, 13 Oct 2017 02:53:01 -0400
>> Subject: [PATCH] ffmpeg_opt: deprecate the hwaccel_lax_profile_check option
>>
>> deprecate hwaccel_lax_profile_check. This only was used for VAAPI
>> hwaccel decoder, now use per-stream hwaccel_flags for all hwaccel
>> decoders.
>>
>> Signed-off-by: Jun Zhao <jun.zhao@intel.com>
>> ---
>>  fftools/ffmpeg_opt.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
>> index 100fa76e46..f1c96ce08c 100644
>> --- a/fftools/ffmpeg_opt.c
>> +++ b/fftools/ffmpeg_opt.c
>> @@ -100,7 +100,7 @@ const HWAccel hwaccels[] = {
>>  #endif
>>      { 0 },
>>  };
>> -int hwaccel_lax_profile_check = 0;
>> +attribute_deprecated int hwaccel_lax_profile_check = 0;
>>  AVBufferRef *hw_device_ctx;
>>  HWDevice *filter_hw_device;
>>  
>> -- 
>> 2.11.0
> Having thought about this a bit further and searched for uses, I now agree with your original position that the option should just be removed.  Results in google are /all/ patches to do with it, links to the code, or appearances of the message which was in some versions last year suggesting its use.
>
> I'll apply your original patch for this (<https://lists.ffmpeg.org/pipermail/ffmpeg-devel/2017-October/217670.html>) tomorrow if there are no objections.
>
> Thanks,
>
> - Mark
>
> (Aside: the patch just sent doesn't actually do what you want - it only deprecates the variable and triggers warnings building ffmpeg.c, but doesn't say anything about the option itself at runtime.)
Got it, thanks.
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel

Patch hide | download patch | download mbox

diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
index 100fa76e46..f1c96ce08c 100644
--- a/fftools/ffmpeg_opt.c
+++ b/fftools/ffmpeg_opt.c
@@ -100,7 +100,7 @@  const HWAccel hwaccels[] = {
 #endif
     { 0 },
 };
-int hwaccel_lax_profile_check = 0;
+attribute_deprecated int hwaccel_lax_profile_check = 0;
 AVBufferRef *hw_device_ctx;
 HWDevice *filter_hw_device;