From bcc19a622d8fd9db60cf9a4d45acf491b86198ca Mon Sep 17 00:00:00 2001 From: TolyaTalamanov Date: Mon, 12 Sep 2022 17:54:00 +0100 Subject: [PATCH 1/2] Replace MFX major version assertion to warning --- modules/gapi/src/streaming/onevpl/source_priv.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/modules/gapi/src/streaming/onevpl/source_priv.cpp b/modules/gapi/src/streaming/onevpl/source_priv.cpp index e8d26b41e2..c2762d0079 100644 --- a/modules/gapi/src/streaming/onevpl/source_priv.cpp +++ b/modules/gapi/src/streaming/onevpl/source_priv.cpp @@ -227,16 +227,15 @@ GSource::Priv::Priv(std::shared_ptr provider, // TODO Add factory static method in ProcessingEngineBase if (mfx_impl_description->ApiVersion.Major >= VPL_NEW_API_MAJOR_VERSION) { - GAPI_Assert(false && + GAPI_LOG_WARNING(NULL, "GSource mfx_impl_description->ApiVersion.Major >= VPL_NEW_API_MAJOR_VERSION" - " - is not implemented"); + " - is not implemented. G-API only supports an older version of OneVPL API."); + } + const auto& transcode_params = VPLLegacyTranscodeEngine::get_vpp_params(preferred_params); + if (!transcode_params.empty()) { + engine.reset(new VPLLegacyTranscodeEngine(std::move(acceleration))); } else { - const auto& transcode_params = VPLLegacyTranscodeEngine::get_vpp_params(preferred_params); - if (!transcode_params.empty()) { - engine.reset(new VPLLegacyTranscodeEngine(std::move(acceleration))); - } else { - engine.reset(new VPLLegacyDecodeEngine(std::move(acceleration))); - } + engine.reset(new VPLLegacyDecodeEngine(std::move(acceleration))); } } From 5ea912e7784bde39925617e3553de2cbb5077a93 Mon Sep 17 00:00:00 2001 From: TolyaTalamanov Date: Tue, 13 Sep 2022 08:28:34 +0100 Subject: [PATCH 2/2] Change warning message --- modules/gapi/src/streaming/onevpl/source_priv.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/gapi/src/streaming/onevpl/source_priv.cpp b/modules/gapi/src/streaming/onevpl/source_priv.cpp index c2762d0079..bd74ca0a25 100644 --- a/modules/gapi/src/streaming/onevpl/source_priv.cpp +++ b/modules/gapi/src/streaming/onevpl/source_priv.cpp @@ -229,7 +229,7 @@ GSource::Priv::Priv(std::shared_ptr provider, if (mfx_impl_description->ApiVersion.Major >= VPL_NEW_API_MAJOR_VERSION) { GAPI_LOG_WARNING(NULL, "GSource mfx_impl_description->ApiVersion.Major >= VPL_NEW_API_MAJOR_VERSION" - " - is not implemented. G-API only supports an older version of OneVPL API."); + " - is not implemented. Rollback to MFX implementation"); } const auto& transcode_params = VPLLegacyTranscodeEngine::get_vpp_params(preferred_params); if (!transcode_params.empty()) {