mirror of
https://github.com/opencv/opencv.git
synced 2026-07-30 07:43:03 +04:00
Fix GpuMat to correctly calculate dataend when using GpuMat::create().
Add output to createMat() to be used by locateROI test cases.
This commit is contained in:
@@ -184,11 +184,8 @@ void cv::cuda::GpuMat::create(int _rows, int _cols, int _type)
|
||||
if (esz * cols == step)
|
||||
flags |= Mat::CONTINUOUS_FLAG;
|
||||
|
||||
int64 _nettosize = static_cast<int64>(step) * rows;
|
||||
size_t nettosize = static_cast<size_t>(_nettosize);
|
||||
|
||||
datastart = data;
|
||||
dataend = data + nettosize;
|
||||
dataend = data + step * (rows - 1) + cols * esz;
|
||||
|
||||
if (refcount)
|
||||
*refcount = 1;
|
||||
|
||||
Reference in New Issue
Block a user