[FFmpeg-devel] [PATCH 2/4] libvpx: remove pre-1.4.0 checks

James Zern jzern at google.com
Mon Nov 20 21:23:48 EET 2017


On Sun, Nov 19, 2017 at 5:57 AM, James Almer <jamrial at gmail.com> wrote:
> On 11/17/2017 10:50 PM, James Zern wrote:
>> Signed-off-by: James Zern <jzern at google.com>
>> ---
>>  libavcodec/libvpx.c | 12 +-----------
>>  1 file changed, 1 insertion(+), 11 deletions(-)
>>
>> diff --git a/libavcodec/libvpx.c b/libavcodec/libvpx.c
>> index 1eca97a081..36f915a8e5 100644
>> --- a/libavcodec/libvpx.c
>> +++ b/libavcodec/libvpx.c
>> @@ -40,9 +40,7 @@ static const enum AVPixelFormat vp9_pix_fmts_highcol[] = {
>>      AV_PIX_FMT_YUV422P,
>>      AV_PIX_FMT_YUV440P,
>>      AV_PIX_FMT_YUV444P,
>> -#if VPX_IMAGE_ABI_VERSION >= 3
>>      AV_PIX_FMT_GBRP,
>> -#endif
>>      AV_PIX_FMT_NONE
>>  };
>>
>> @@ -60,30 +58,22 @@ static const enum AVPixelFormat vp9_pix_fmts_highbd[] = {
>>      AV_PIX_FMT_YUV422P12,
>>      AV_PIX_FMT_YUV440P12,
>>      AV_PIX_FMT_YUV444P12,
>> -#if VPX_IMAGE_ABI_VERSION >= 3
>>      AV_PIX_FMT_GBRP,
>>      AV_PIX_FMT_GBRP10,
>>      AV_PIX_FMT_GBRP12,
>> -#endif
>>      AV_PIX_FMT_NONE
>>  };
>>  #endif
>>
>>  av_cold void ff_vp9_init_static(AVCodec *codec)
>>  {
>> -    if (    vpx_codec_version_major() < 1
>> -        || (vpx_codec_version_major() == 1 && vpx_codec_version_minor() < 3))
>> -        codec->capabilities |= AV_CODEC_CAP_EXPERIMENTAL;
>>      codec->pix_fmts = vp9_pix_fmts_def;
>
> Does this limited list of pixfmts make sense now that the
> vpx_codec_version_* check below is gone?
>

It shouldn't, but as you pointed out in the configure patch, the
availability of VPX_CODEC_CAP_HIGHBITDEPTH is limited to the encoder
in 1.4.0. The move of this define didn't happen until post 1.6.1.


More information about the ffmpeg-devel mailing list