mirror of
https://github.com/opencv/opencv.git
synced 2024-11-28 05:06:29 +08:00
cuda: fix inplace condition in cv::cuda::flip
This commit is contained in:
parent
5340dc6686
commit
e4b0251e9d
@ -163,7 +163,7 @@ void cv::cuda::flip(InputArray _src, OutputArray _dst, int flipCode, Stream& str
|
||||
|
||||
_dst.create(src.size(), src.type());
|
||||
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;
|
||||
if (isInplace && isSizeOdd)
|
||||
CV_Error(Error::BadROISize, "In-place version of flip only accepts even width/height");
|
||||
|
Loading…
Reference in New Issue
Block a user