我正在使用 c++ 中的 opencv 开发车道检测算法。我进行了仿射变换以将三角形区域提取到蒙版中。
在此步骤之后,我想执行 Canny 边缘检测器。但它不起作用。是因为位转换吗?或者我的问题是什么?
我将主要部分外包给函数 warpTriangle。程序最后在此函数中中断。
错误信息:
OpenCV Error: Assertion failed ((_dst.getObj() != _src.getObj() || _src.type() == (((0) & ((1 << 3) - 1)) + (((1)-1) << 3))) && "Inplace parameters are not supported") in Canny, file /tmp/opencv-20180113-80339-d8g5mw/opencv-3.4.0/modules/imgproc/src/canny.cpp, line 935
libc++abi.dylib: terminating with uncaught exception of type cv::Exception: /tmp/opencv-20180113-80339-d8g5mw/opencv-3.4.0/modules/imgproc/src/canny.cpp:935: error: (-215) (_dst.getObj() != _src.getObj() || _src.type() == (((0) & ((1 << 3) - 1)) + (((1)-1) << 3))) && "Inplace parameters are not supported" in function …