• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

hardware/intel/common/vaapi


Commit MetaInfo

Revisión8718ff7dea8485aba2c67350521ae8d00e118d75 (tree)
Tiempo2017-08-10 15:39:17
AutorPengfei Qu <Pengfei.Qu@inte...>
CommiterXiang, Haihao

Log Message

add brc mode check for AVC when creating the config

v0:this add the RC check for AVC encoder

Fixes #35

Signed-off-by: Pengfei Qu <Pengfei.Qu@intel.com>

Cambiar Resumen

Diferencia incremental

--- a/src/i965_drv_video.c
+++ b/src/i965_drv_video.c
@@ -1296,6 +1296,27 @@ i965_CreateConfig(VADriverContextP ctx,
12961296 vaStatus = VA_STATUS_ERROR_UNSUPPORTED_RT_FORMAT;
12971297 }
12981298
1299+
1300+ if (vaStatus == VA_STATUS_SUCCESS) {
1301+ VAConfigAttrib attrib, *attrib_found;
1302+ attrib.type = VAConfigAttribRateControl;
1303+ attrib_found = i965_lookup_config_attribute(obj_config, attrib.type);
1304+ switch (profile) {
1305+ case VAProfileH264ConstrainedBaseline:
1306+ case VAProfileH264Main:
1307+ case VAProfileH264High:
1308+ if ((entrypoint == VAEntrypointEncSlice) &&
1309+ !(attrib_found->value & i965->codec_info->h264_brc_mode))
1310+ vaStatus = VA_STATUS_ERROR_INVALID_CONFIG;
1311+ else if ((entrypoint == VAEntrypointEncSliceLP) &&
1312+ !(attrib_found->value & i965->codec_info->lp_h264_brc_mode))
1313+ vaStatus = VA_STATUS_ERROR_INVALID_CONFIG;
1314+ break;
1315+ default:
1316+ break;
1317+ }
1318+ }
1319+
12991320 if (vaStatus == VA_STATUS_SUCCESS) {
13001321 VAConfigAttrib attrib;
13011322 attrib.type = VAConfigAttribEncMaxSlices;