On Wed, May 27, 2015 at 7:24 PM, James Almer <[email protected]> wrote:
>As Luca said, require_pkg_config. If you use require, "vpx >= 1.4.0" is just 
>used as a name
>to report a failure. It does not check for that version.

I swear I couldn't get it working with just require_pkg_config, thanks
for showing how to do that in the next email.

>> diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
>> index 3440126..16af20c 100644
>> --- a/libavcodec/avcodec.h
>> +++ b/libavcodec/avcodec.h
>> @@ -2702,6 +2702,10 @@ typedef struct AVCodecContext {
>>  #define FF_PROFILE_JPEG2000_DCINEMA_2K              3
>>  #define FF_PROFILE_JPEG2000_DCINEMA_4K              4
>>
>> +#define FF_PROFILE_VP9_0                            0
>> +#define FF_PROFILE_VP9_1                            1
>> +#define FF_PROFILE_VP9_2                            2
>> +#define FF_PROFILE_VP9_3                            3
>
> Even if it's a simple change, credit where credit is due would be nice.

credit to whom and for what?

>> -   if (avctx->profile != FF_PROFILE_UNKNOWN)
>> -       enccfg.g_profile = avctx->profile;
>> +    if (avctx->profile != FF_PROFILE_UNKNOWN)
>> +        enccfg.g_profile = avctx->profile;
>> +    else if (avctx->pix_fmt == AV_PIX_FMT_YUV440P)
>> +        avctx->profile = enccfg.g_profile = FF_PROFILE_VP9_0;
>> +    else
>> +        avctx->profile = enccfg.g_profile = FF_PROFILE_VP9_1;
>
> This is wrong.
>
> Profile 0 = 8 bit yuv420p
> Profile 1 = 8 bit yuv422/440/444p
> Profile 2 = 10/12 bit yuv420p
> Profile 3 = 10/12 bit yuv422/440/444p

typo I had meant yuv420p in the first check.

>>  AVCodec ff_libvpx_vp9_encoder = {
>>      .name           = "libvpx-vp9",
>>      .long_name      = NULL_IF_CONFIG_SMALL("libvpx VP9"),
>> @@ -643,7 +652,12 @@ AVCodec ff_libvpx_vp9_encoder = {
>>      .encode2        = vp8_encode,
>>      .close          = vp8_free,
>>      .capabilities   = CODEC_CAP_DELAY | CODEC_CAP_AUTO_THREADS,
>> -    .pix_fmts       = (const enum AVPixelFormat[]){ AV_PIX_FMT_YUV420P, 
>> AV_PIX_FMT_NONE },
>> +    .pix_fmts       = (const enum AVPixelFormat[]) {
>> +        AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUV422P, AV_PIX_FMT_YUV444P,
>> +        AV_PIX_FMT_YUV440P,
>> +        AV_PIX_FMT_NONE,
>
> What's the point setting up all those pix_fmts above if you're not allowing 
> their usage
> here?

just for completeness in the future, when new formats will be added
I can drop them if you think it's redundant.
-- 
Vittorio
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to