From 3636eec789951ee18be42f8de66f0874cbcba7b7 Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Wed, 27 Jul 2011 20:13:50 +0000 Subject: [PATCH] fixed flow matrix dimensionality in EMD --- modules/imgproc/src/emd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/imgproc/src/emd.cpp b/modules/imgproc/src/emd.cpp index fd7f9a48e0..734e7aaaf9 100644 --- a/modules/imgproc/src/emd.cpp +++ b/modules/imgproc/src/emd.cpp @@ -1150,7 +1150,7 @@ float cv::EMD( InputArray _signature1, InputArray _signature2, CvMat _ccost = cost, _cflow; if( _flow.needed() ) { - _flow.create((int)signature1.total(), (int)signature2.total(), CV_32F); + _flow.create(signature1.rows, signature2.rows, CV_32F); flow = _flow.getMat(); _cflow = flow; }