hardware/intel/common/vaapi
Revisión | 8e9b449ee437e459dfe5b757591417152dc28ec2 (tree) |
---|---|
Tiempo | 2017-07-13 13:17:12 |
Autor | peng.chen <peng.c.chen@inte...> |
Commiter | Xiang, Haihao |
Add HEVC ROI attributes for VAConfigAttribEncROI
Fixes #179
Signed-off-by: peng.chen <peng.c.chen@intel.com>
@@ -1084,6 +1084,8 @@ i965_GetConfigAttributes(VADriverContextP ctx, | ||
1084 | 1084 | case VAConfigAttribEncROI: |
1085 | 1085 | if (entrypoint == VAEntrypointEncSlice || |
1086 | 1086 | entrypoint == VAEntrypointEncSliceLP) { |
1087 | + VAConfigAttribValEncROI *roi_config = | |
1088 | + (VAConfigAttribValEncROI *) & (attrib_list[i].value); | |
1087 | 1089 | |
1088 | 1090 | if (profile == VAProfileH264ConstrainedBaseline || |
1089 | 1091 | profile == VAProfileH264Main || |
@@ -1093,10 +1095,6 @@ i965_GetConfigAttributes(VADriverContextP ctx, | ||
1093 | 1095 | entrypoint == VAEntrypointEncSlice) |
1094 | 1096 | attrib_list[i].value = 0; |
1095 | 1097 | else { |
1096 | - | |
1097 | - VAConfigAttribValEncROI *roi_config = | |
1098 | - (VAConfigAttribValEncROI *) & (attrib_list[i].value); | |
1099 | - | |
1100 | 1098 | if (entrypoint == VAEntrypointEncSliceLP) { |
1101 | 1099 | roi_config->bits.num_roi_regions = 3; |
1102 | 1100 | roi_config->bits.roi_rc_priority_support = 0; |
@@ -1108,6 +1106,12 @@ i965_GetConfigAttributes(VADriverContextP ctx, | ||
1108 | 1106 | roi_config->bits.roi_rc_qp_delat_support = 1; |
1109 | 1107 | } |
1110 | 1108 | } |
1109 | + } else if (profile == VAProfileHEVCMain || | |
1110 | + profile == VAProfileHEVCMain10) { | |
1111 | + roi_config->bits.num_roi_regions = | |
1112 | + I965_MAX_NUM_ROI_REGIONS; | |
1113 | + roi_config->bits.roi_rc_priority_support = 1; | |
1114 | + roi_config->bits.roi_rc_qp_delat_support = 1; | |
1111 | 1115 | } else { |
1112 | 1116 | attrib_list[i].value = 0; |
1113 | 1117 | } |