1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-30 15:53:03 +04:00

Check for empty Mat in compare, operator= and RNG::fill, fixed related tests

This commit is contained in:
Maksim Shabunin
2018-07-17 17:50:50 +03:00
parent 1da46fe6fb
commit c473718bc2
5 changed files with 8 additions and 4 deletions
+2
View File
@@ -511,6 +511,8 @@ static RandnScaleFunc randnScaleTab[] =
void RNG::fill( InputOutputArray _mat, int disttype,
InputArray _param1arg, InputArray _param2arg, bool saturateRange )
{
if (_mat.empty())
return;
Mat mat = _mat.getMat(), _param1 = _param1arg.getMat(), _param2 = _param2arg.getMat();
int depth = mat.depth(), cn = mat.channels();
AutoBuffer<double> _parambuf;