On Sat, Dec 14, 2013 at 3:50 PM, Guillaume Martres <[email protected]> wrote:
> From: Gildas Cocherel <[email protected]>
>
> ---
>  libavcodec/avcodec.h | 5 +++++
>  libavcodec/hevc.c    | 9 +++++++++
>  2 files changed, 14 insertions(+)
>
> diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
> index 0e6ac05..9531c85 100644
> --- a/libavcodec/avcodec.h
> +++ b/libavcodec/avcodec.h
> @@ -2662,6 +2662,11 @@ typedef struct AVCodecContext {
>  #define FF_PROFILE_JPEG2000_DCINEMA_2K              3
>  #define FF_PROFILE_JPEG2000_DCINEMA_4K              4
>
> +
> +#define FF_PROFILE_HEVC_MAIN                        1
> +#define FF_PROFILE_HEVC_MAIN_10                     2
> +#define FF_PROFILE_HEVC_MAIN_STILL_PICTURE          3
> +
>      /**
>       * level
>       * - encoding: Set by user.

Does adding defines in a public header require a (minor/patch) bump?
Good to go if not.
Vittorio

> diff --git a/libavcodec/hevc.c b/libavcodec/hevc.c
> index 4af5aee..229241b 100644
> --- a/libavcodec/hevc.c
> +++ b/libavcodec/hevc.c
> @@ -3170,6 +3170,14 @@ static void hevc_decode_flush(AVCodecContext *avctx)
>
>  #define OFFSET(x) offsetof(HEVCContext, x)
>  #define PAR (AV_OPT_FLAG_DECODING_PARAM | AV_OPT_FLAG_VIDEO_PARAM)
> +
> +static const AVProfile profiles[] = {
> +    { FF_PROFILE_HEVC_MAIN,                 "Main"              },
> +    { FF_PROFILE_HEVC_MAIN_10,              "Main10"            },
> +    { FF_PROFILE_HEVC_MAIN_STILL_PICTURE,   "MainStillPicture"  },
> +    { FF_PROFILE_UNKNOWN },
> +};
> +
>  static const AVOption options[] = {
>      { "apply_defdispwin", "Apply default display window from VUI", 
> OFFSET(apply_defdispwin),
>          AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, PAR },
> @@ -3198,4 +3206,5 @@ AVCodec ff_hevc_decoder = {
>      .init_thread_copy      = hevc_init_thread_copy,
>      .capabilities          = CODEC_CAP_DR1 | CODEC_CAP_DELAY |
>                               CODEC_CAP_FRAME_THREADS,
> +    .profiles              = NULL_IF_CONFIG_SMALL(profiles),
>  };
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to