diff options
author | Sreerenj Balachandran <sreerenj.balachandran@intel.com> | 2017-08-18 11:19:44 -0700 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2017-08-23 15:44:15 +0800 |
commit | 44e42f60e676eb04978a05632df6caa4db3b54fe (patch) | |
tree | 8b48b60a81bc76c7145b3e8069b73032f31d3e3b | |
parent | 98c364159af19b7fe80120baceff585bd69e804d (diff) | |
download | libva-intel-driver-44e42f60e676eb04978a05632df6caa4db3b54fe.tar.gz |
FEI: tests: Add VAEntrypointFEI
Add the FEI entrypoint in test case scenarios
Fixes #228
-rw-r--r-- | test/i965_avce_config_test.cpp | 46 | ||||
-rw-r--r-- | test/i965_avce_context_test.cpp | 3 | ||||
-rw-r--r-- | test/i965_avce_test_common.cpp | 7 | ||||
-rw-r--r-- | test/i965_streamable.h | 2 |
4 files changed, 56 insertions, 2 deletions
diff --git a/test/i965_avce_config_test.cpp b/test/i965_avce_config_test.cpp index 4830af9d..e241bb82 100644 --- a/test/i965_avce_config_test.cpp +++ b/test/i965_avce_config_test.cpp @@ -48,7 +48,8 @@ VAStatus H264NotSupported() EXPECT_PTR(i965); if (!HAS_H264_DECODING(i965) - && !HAS_LP_H264_ENCODING(i965)) + && !HAS_LP_H264_ENCODING(i965) + && !HAS_FEI_H264_ENCODING(i965)) return ProfileNotSupported(); return EntrypointNotSupported(); @@ -63,7 +64,24 @@ VAStatus H264LPNotSupported() EXPECT_PTR(i965); if (!HAS_H264_DECODING(i965) - && !HAS_H264_ENCODING(i965)) + && !HAS_H264_ENCODING(i965) + && !HAS_FEI_H264_ENCODING(i965)) + return ProfileNotSupported(); + + return EntrypointNotSupported(); +} + +VAStatus H264FEINotSupported() +{ + I965TestEnvironment *env(I965TestEnvironment::instance()); + EXPECT_PTR(env); + + struct i965_driver_data *i965(*env); + EXPECT_PTR(i965); + + if (!HAS_H264_DECODING(i965) + && !HAS_H264_ENCODING(i965) + && !HAS_LP_H264_ENCODING(i965)) return ProfileNotSupported(); return EntrypointNotSupported(); @@ -114,6 +132,24 @@ VAStatus HasLPEncodeSupport() return H264LPNotSupported(); } + +VAStatus HasFEIEncodeSupport() +{ + I965TestEnvironment *env(I965TestEnvironment::instance()); + EXPECT_PTR(env); + + struct i965_driver_data *i965(*env); + EXPECT_PTR(i965); + + if (IS_SKL(i965->intel.device_info)) + return VA_STATUS_SUCCESS; + + if (HAS_FEI_H264_ENCODING(i965)) + return VA_STATUS_SUCCESS; + + return H264FEINotSupported(); +} + VAStatus HasMVCEncodeSupport() { I965TestEnvironment *env(I965TestEnvironment::instance()); @@ -132,26 +168,32 @@ static const std::vector<ConfigTestInput> inputs = { {VAProfileH264Baseline, VAEntrypointEncSlice, &ProfileNotSupported}, {VAProfileH264Baseline, VAEntrypointEncSliceLP, &ProfileNotSupported}, {VAProfileH264Baseline, VAEntrypointEncPicture, &ProfileNotSupported}, + {VAProfileH264Baseline, VAEntrypointFEI, &ProfileNotSupported}, {VAProfileH264ConstrainedBaseline, VAEntrypointEncSlice, &HasEncodeSupport}, {VAProfileH264ConstrainedBaseline, VAEntrypointEncSliceLP, &HasLPEncodeSupport}, {VAProfileH264ConstrainedBaseline, VAEntrypointEncPicture, &H264NotSupported}, + {VAProfileH264ConstrainedBaseline, VAEntrypointFEI, &HasFEIEncodeSupport}, {VAProfileH264Main, VAEntrypointEncSlice, &HasEncodeSupport}, {VAProfileH264Main, VAEntrypointEncSliceLP, &HasLPEncodeSupport}, {VAProfileH264Main, VAEntrypointEncPicture, &H264NotSupported}, + {VAProfileH264Main, VAEntrypointFEI, &HasFEIEncodeSupport}, {VAProfileH264High, VAEntrypointEncSlice, &HasEncodeSupport}, {VAProfileH264High, VAEntrypointEncSliceLP, &HasLPEncodeSupport}, {VAProfileH264High, VAEntrypointEncPicture, &H264NotSupported}, + {VAProfileH264High, VAEntrypointFEI, &HasFEIEncodeSupport}, {VAProfileH264MultiviewHigh, VAEntrypointEncSlice, &HasMVCEncodeSupport}, {VAProfileH264MultiviewHigh, VAEntrypointEncSliceLP, &H264MVCNotSupported}, {VAProfileH264MultiviewHigh, VAEntrypointEncPicture, &H264MVCNotSupported}, + {VAProfileH264MultiviewHigh, VAEntrypointFEI, &H264MVCNotSupported}, {VAProfileH264StereoHigh, VAEntrypointEncSlice, &HasMVCEncodeSupport}, {VAProfileH264StereoHigh, VAEntrypointEncSliceLP, &H264MVCNotSupported}, {VAProfileH264StereoHigh, VAEntrypointEncPicture, &H264MVCNotSupported}, + {VAProfileH264StereoHigh, VAEntrypointFEI, &H264MVCNotSupported}, }; INSTANTIATE_TEST_CASE_P( diff --git a/test/i965_avce_context_test.cpp b/test/i965_avce_context_test.cpp index 494d51d5..039c05d5 100644 --- a/test/i965_avce_context_test.cpp +++ b/test/i965_avce_context_test.cpp @@ -276,10 +276,13 @@ INSTANTIATE_TEST_CASE_P( AVCEncode, AVCEContextTest, ::testing::Values( std::make_tuple(VAProfileH264ConstrainedBaseline, VAEntrypointEncSlice), std::make_tuple(VAProfileH264ConstrainedBaseline, VAEntrypointEncSliceLP), + std::make_tuple(VAProfileH264ConstrainedBaseline, VAEntrypointFEI), std::make_tuple(VAProfileH264Main, VAEntrypointEncSlice), std::make_tuple(VAProfileH264Main, VAEntrypointEncSliceLP), + std::make_tuple(VAProfileH264Main, VAEntrypointFEI), std::make_tuple(VAProfileH264High, VAEntrypointEncSlice), std::make_tuple(VAProfileH264High, VAEntrypointEncSliceLP), + std::make_tuple(VAProfileH264High, VAEntrypointFEI), std::make_tuple(VAProfileH264MultiviewHigh, VAEntrypointEncSlice), std::make_tuple(VAProfileH264StereoHigh, VAEntrypointEncSlice) ) diff --git a/test/i965_avce_test_common.cpp b/test/i965_avce_test_common.cpp index 46a2b20b..1948c871 100644 --- a/test/i965_avce_test_common.cpp +++ b/test/i965_avce_test_common.cpp @@ -59,6 +59,13 @@ VAStatus CheckSupported(VAProfile profile, VAEntrypoint entrypoint) if (HAS_LP_H264_ENCODING(i965)) { return VA_STATUS_SUCCESS; } + } else if (entrypoint == VAEntrypointFEI) { + if (IS_SKL(i965->intel.device_info)) { + return VA_STATUS_SUCCESS; + } + if (HAS_FEI_H264_ENCODING(i965)) { + return VA_STATUS_SUCCESS; + } } break; diff --git a/test/i965_streamable.h b/test/i965_streamable.h index 0f7e1291..71fb88fa 100644 --- a/test/i965_streamable.h +++ b/test/i965_streamable.h @@ -471,6 +471,8 @@ operator<<(std::ostream& os, const VAEntrypoint& entrypoint) return os << "VAEntrypointEncSliceLP"; case VAEntrypointEncPicture: return os << "VAEntrypointEncPicture"; + case VAEntrypointFEI: + return os << "VAEntrypointFEI"; default: return os << "Unknown VAEntrypoint: " << static_cast<int>(entrypoint); } |