1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

Merge pull request #2808 from ilya-lavrenov:tapi_normalize_mask

This commit is contained in:
Alexander Alekhin
2014-06-04 18:10:13 +04:00
committed by OpenCV Buildbot
6 changed files with 167 additions and 9 deletions
+17
View File
@@ -2051,6 +2051,23 @@ void _InputArray::copyTo(const _OutputArray& arr) const
CV_Error(Error::StsNotImplemented, "");
}
void _InputArray::copyTo(const _OutputArray& arr, const _InputArray & mask) const
{
int k = kind();
if( k == NONE )
arr.release();
else if( k == MAT || k == MATX || k == STD_VECTOR )
{
Mat m = getMat();
m.copyTo(arr, mask);
}
else if( k == UMAT )
((UMat*)obj)->copyTo(arr, mask);
else
CV_Error(Error::StsNotImplemented, "");
}
bool _OutputArray::fixedSize() const
{
return (flags & FIXED_SIZE) == FIXED_SIZE;