Commit c5de129c authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

Merge pull request #3222 from dmitrygribanov:dg/2.4-stitching-wave-correction-bugfix

parents 533dd852 8a1d3929
......@@ -616,7 +616,14 @@ void waveCorrect(vector<Mat> &rmats, WaveCorrectKind kind)
for (size_t i = 0; i < rmats.size(); ++i)
img_k += rmats[i].col(2);
Mat rg0 = rg1.cross(img_k);
rg0 /= norm(rg0);
double rg0_norm = norm(rg0);
if( rg0_norm <= DBL_MIN )
{
return;
}
rg0 /= rg0_norm;
Mat rg2 = rg0.cross(rg1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment