Merge pull request #2967 from LeonidBeynenson:bugfix_wave_correction_wrong_result

This commit is contained in:
Vadim Pisarevsky 2014-07-15 08:10:04 +00:00
commit faac7f18c7

View File

@ -589,6 +589,11 @@ void waveCorrect(vector<Mat> &rmats, WaveCorrectKind kind)
#if ENABLE_LOG
int64 t = getTickCount();
#endif
if (rmats.size() <= 1)
{
LOGLN("Wave correcting, time: " << ((getTickCount() - t) / getTickFrequency()) << " sec");
return;
}
Mat moment = Mat::zeros(3, 3, CV_32F);
for (size_t i = 0; i < rmats.size(); ++i)