diff --git a/services/data_process/src/pipeline_node/colorspace_conversion/color_format_process.cpp b/services/data_process/src/pipeline_node/colorspace_conversion/color_format_process.cpp index 993f685ff8e3b1fe6e9f53d08b56451e2c338d60..b6cb25070710987ceabe814907336376b21df005 100644 --- a/services/data_process/src/pipeline_node/colorspace_conversion/color_format_process.cpp +++ b/services/data_process/src/pipeline_node/colorspace_conversion/color_format_process.cpp @@ -55,7 +55,8 @@ int32_t ColorFormatProcess::InitNode(const VideoConfigParams& sourceConfig, cons bool ColorFormatProcess::IsConvertible(const VideoConfigParams& sourceConfig, const VideoConfigParams& targetConfig) { - return (sourceConfig.GetVideoformat() == Videoformat::NV12 && targetConfig.GetVideoformat() == Videoformat::NV21 && + return ((sourceConfig.GetVideoformat() == targetConfig.GetVideoformat() || + (sourceConfig.GetVideoformat() == Videoformat::NV12 && targetConfig.GetVideoformat() == Videoformat::NV21)) && sourceConfig.GetWidth() == targetConfig.GetWidth() && sourceConfig.GetHeight() == targetConfig.GetHeight()); }