OpenCL version of cv::buildPyramid

This commit is contained in:
Ilya Lavrenov
2014-01-27 18:34:19 +04:00
parent d9b24457fa
commit 48a084c236
4 changed files with 57 additions and 0 deletions

View File

@@ -207,6 +207,7 @@ public:
virtual bool fixedType() const;
virtual bool needed() const;
virtual Mat& getMatRef(int i=-1) const;
virtual UMat& getUMatRef(int i=-1) const;
virtual cuda::GpuMat& getGpuMatRef() const;
virtual ogl::Buffer& getOGlBufferRef() const;
virtual cuda::CudaMem& getCudaMemRef() const;

View File

@@ -2484,6 +2484,23 @@ Mat& _OutputArray::getMatRef(int i) const
}
}
UMat& _OutputArray::getUMatRef(int i) const
{
int k = kind();
if( i < 0 )
{
CV_Assert( k == UMAT );
return *(UMat*)obj;
}
else
{
CV_Assert( k == STD_VECTOR_UMAT );
std::vector<UMat>& v = *(std::vector<UMat>*)obj;
CV_Assert( i < (int)v.size() );
return v[i];
}
}
cuda::GpuMat& _OutputArray::getGpuMatRef() const
{
int k = kind();