hardware/intel/common/libva
Revisão | 075566a6e1e672e8ff88c54c08503539cb8bd360 (tree) |
---|---|
Hora | 2017-11-22 16:27:31 |
Autor | pylee <penne.y.lee@inte...> |
Commiter | Xiang, Haihao |
add VAConfigAttribDecJPEG attributes
VAConfigAttribDecJPEG is for JPEG decode capabilities such as rotation
Signed-off-by: Carl.Zhang <carl.zhang@intel.com>
@@ -427,7 +427,14 @@ typedef enum | ||
427 | 427 | * See \c VA_DEC_SLICE_MODE_xxx for the list of slice decoding modes. |
428 | 428 | */ |
429 | 429 | VAConfigAttribDecSliceMode = 6, |
430 | - | |
430 | + /** | |
431 | + * \brief JPEG decoding attribute. Read-only. | |
432 | + * | |
433 | + * This attribute exposes a number of capabilities of the underlying | |
434 | + * JPEG implementation. The attribute value is partitioned into fields as defined in the | |
435 | + * VAConfigAttribValDecJPEG union. | |
436 | + */ | |
437 | + VAConfigAttribDecJPEG = 7, | |
431 | 438 | /** @name Attributes for encoding */ |
432 | 439 | /**@{*/ |
433 | 440 | /** |
@@ -615,6 +622,19 @@ typedef struct _VAConfigAttrib { | ||
615 | 622 | #define VA_DEC_SLICE_MODE_NORMAL 0x00000001 |
616 | 623 | /** \brief Driver supports base mode for slice decoding */ |
617 | 624 | #define VA_DEC_SLICE_MODE_BASE 0x00000002 |
625 | + | |
626 | +/** @name Attribute values for VAConfigAttribDecJPEG */ | |
627 | +/**@{*/ | |
628 | +typedef union _VAConfigAttribValDecJPEG { | |
629 | + struct{ | |
630 | + /** \brief Set to (1 << VA_ROTATION_xxx) for supported rotation angles. */ | |
631 | + uint32_t rotation : 4; | |
632 | + /** \brief Reserved for future use. */ | |
633 | + uint32_t reserved : 28; | |
634 | + }bits; | |
635 | + uint32_t value; | |
636 | + uint32_t va_reserved[VA_PADDING_LOW]; | |
637 | +} VAConfigAttribValDecJPEG; | |
618 | 638 | /**@}*/ |
619 | 639 | |
620 | 640 | /** @name Attribute values for VAConfigAttribEncPackedHeaders */ |
@@ -71,8 +71,12 @@ typedef struct _VAPictureParameterBufferJPEGBaseline { | ||
71 | 71 | /** \brief Number of components in frame (Nf). */ |
72 | 72 | uint8_t num_components; |
73 | 73 | |
74 | + /** \brief Input color space 0: YUV, 1: RGB, 2: BGR, others: reserved */ | |
75 | + uint8_t color_space; | |
76 | + /** \brief Set to VA_ROTATION_* for a single rotation angle reported by VAConfigAttribDecJPEG. */ | |
77 | + uint32_t rotation; | |
74 | 78 | /** \brief Reserved bytes for future use, must be zero */ |
75 | - uint32_t va_reserved[VA_PADDING_MEDIUM]; | |
79 | + uint32_t va_reserved[VA_PADDING_MEDIUM - 1]; | |
76 | 80 | } VAPictureParameterBufferJPEGBaseline; |
77 | 81 | |
78 | 82 | /** |
@@ -98,6 +98,7 @@ const char *vaConfigAttribTypeStr(VAConfigAttribType configAttribType) | ||
98 | 98 | TOSTR(VAConfigAttribEncRateControlExt); |
99 | 99 | TOSTR(VAConfigAttribFEIFunctionType); |
100 | 100 | TOSTR(VAConfigAttribFEIMVPredictors); |
101 | + TOSTR(VAConfigAttribDecJPEG); | |
101 | 102 | case VAConfigAttribTypeMax: break; |
102 | 103 | } |
103 | 104 | return "<unknown config attribute type>"; |