Fixed bug in cv::detail::waveCorrect
The function makes wave correction of a stitched panorama. Earlier it gave wrong results for panorama made from 1 frame.
This commit is contained in:
parent
2df3abe16b
commit
79878a57a9
@ -589,6 +589,11 @@ void waveCorrect(vector<Mat> &rmats, WaveCorrectKind kind)
|
|||||||
#if ENABLE_LOG
|
#if ENABLE_LOG
|
||||||
int64 t = getTickCount();
|
int64 t = getTickCount();
|
||||||
#endif
|
#endif
|
||||||
|
if (rmats.size() <= 1)
|
||||||
|
{
|
||||||
|
LOGLN("Wave correcting, time: " << ((getTickCount() - t) / getTickFrequency()) << " sec");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
Mat moment = Mat::zeros(3, 3, CV_32F);
|
Mat moment = Mat::zeros(3, 3, CV_32F);
|
||||||
for (size_t i = 0; i < rmats.size(); ++i)
|
for (size_t i = 0; i < rmats.size(); ++i)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user