![]() |
OpenCV 4.11.0
开源计算机视觉库
|
函数 | |
| void | cv::cann::cvtColor (const AscendMat &src, AscendMat &dst, int code, int dstCn=0, AscendStream &stream=AscendStream::Null()) |
| void | cv::cann::cvtColor (const InputArray src, OutputArray dst, int code, int dstCn=0, AscendStream &stream=AscendStream::Null()) |
| 将图像从一种颜色空间转换为另一种颜色空间。 | |
| void cv::cann::cvtColor | ( | const AscendMat & | src, |
| AscendMat & | dst, | ||
| int | code, | ||
| int | dstCn = 0, | ||
| AscendStream & | stream = AscendStream::Null() ) |
#include <opencv2/cann_interface.hpp>
这是一个重载的成员函数,为了方便提供。它与上面的函数的区别仅在于它接受的参数。
| void cv::cann::cvtColor | ( | const InputArray | src, |
| OutputArray | dst, | ||
| int | code, | ||
| int | dstCn = 0, | ||
| AscendStream & | stream = AscendStream::Null() ) |
#include <opencv2/cann_interface.hpp>
将图像从一种颜色空间转换为另一种颜色空间。
| src | 源图像,深度为 CV_8U、CV_16U 或 CV_32F,通道数为 1、3 或 4。 |
| dst | 目标图像。 |
| code | 颜色空间转换代码。详情请参见 cv::ColorConversionCodes。 |
| dstCn | 目标图像的通道数。如果参数为 0,则通道数将根据 src 和 code 自动推导。 |
| stream | 异步版本的 AscendStream。 |