1
0
mirror of https://github.com/opencv/opencv_contrib.git synced 2025-10-16 13:57:05 +08:00

Merge moved code from opencv/3.4

This commit is contained in:
Alexander Alekhin
2021-04-01 21:47:26 +00:00

View File

@@ -163,7 +163,7 @@ void cv::cuda::flip(InputArray _src, OutputArray _dst, int flipCode, Stream& str
_dst.create(src.size(), src.type()); _dst.create(src.size(), src.type());
GpuMat dst = getOutputMat(_dst, src.size(), src.type(), stream); GpuMat dst = getOutputMat(_dst, src.size(), src.type(), stream);
bool isInplace = (src.data == dst.data) || (src.refcount == dst.refcount); bool isInplace = (src.data == dst.data);
bool isSizeOdd = (src.cols & 1) == 1 || (src.rows & 1) == 1; bool isSizeOdd = (src.cols & 1) == 1 || (src.rows & 1) == 1;
if (isInplace && isSizeOdd) if (isInplace && isSizeOdd)
CV_Error(Error::BadROISize, "In-place version of flip only accepts even width/height"); CV_Error(Error::BadROISize, "In-place version of flip only accepts even width/height");