From dcbd65bf03d0755bbdaa1e69b81480e8de1fb8e2 Mon Sep 17 00:00:00 2001 From: Carl Zhang Date: Wed, 29 May 2019 09:51:15 -0400 Subject: add attribute for max frame size Signed-off-by: Carl Zhang --- va/va.h | 22 ++++++++++++++++++++++ va/va_str.c | 1 + 2 files changed, 23 insertions(+) diff --git a/va/va.h b/va/va.h index 13d0069..65068f7 100644 --- a/va/va.h +++ b/va/va.h @@ -756,6 +756,11 @@ typedef enum * support for QP info for buffer #VAEncQpBuffer. */ VAConfigAttribQPBlockSize = 37, + /** + * \brief encode max frame size attribute. Read-only + * attribute value \c VAConfigAttribValMaxFrameSize represent max frame size support + */ + VAConfigAttribMaxFrameSize = 38, /**@}*/ VAConfigAttribTypeMax } VAConfigAttribType; @@ -941,6 +946,23 @@ typedef union _VAConfigAttribValDecJPEG { #define VA_ENC_SLICE_STRUCTURE_ARBITRARY_ROWS 0x00000010 /**@}*/ +/** \brief Attribute value for VAConfigAttribMaxFrameSize */ +typedef union _VAConfigAttribValMaxFrameSize { + struct { + /** \brief support max frame size + * if max_frame_size == 1, VAEncMiscParameterTypeMaxFrameSize/VAEncMiscParameterBufferMaxFrameSize + * could be used to set the frame size, if multiple_pass also equal 1, VAEncMiscParameterTypeMultiPassFrameSize + * VAEncMiscParameterBufferMultiPassFrameSize could be used to set frame size and pass information + */ + uint32_t max_frame_size : 1; + /** \brief multiple_pass support */ + uint32_t multiple_pass : 1; + /** \brief reserved bits for future, must be zero*/ + uint32_t reserved :30; + } bits; + uint32_t value; +} VAConfigAttribValMaxFrameSize; + /** \brief Attribute value for VAConfigAttribEncJPEG */ typedef union _VAConfigAttribValEncJPEG { struct { diff --git a/va/va_str.c b/va/va_str.c index bda1a72..4ce1ea1 100644 --- a/va/va_str.c +++ b/va/va_str.c @@ -123,6 +123,7 @@ const char *vaConfigAttribTypeStr(VAConfigAttribType configAttribType) TOSTR(VAConfigAttribCustomRoundingControl); TOSTR(VAConfigAttribQPBlockSize); TOSTR(VAConfigAttribStats); + TOSTR(VAConfigAttribMaxFrameSize); case VAConfigAttribTypeMax: break; } return ""; -- cgit v1.2.1