Commit 4c35449b authored by Andrey Pavlenko's avatar Andrey Pavlenko Committed by OpenCV Buildbot

Merge pull request #1139 from StevenPuttemans:bugfix_3101

parents d138f771 dd0481ef
...@@ -886,11 +886,13 @@ void ellipse2Poly( Point center, Size axes, int angle, ...@@ -886,11 +886,13 @@ void ellipse2Poly( Point center, Size axes, int angle,
Point pt; Point pt;
pt.x = cvRound( cx + x * alpha - y * beta ); pt.x = cvRound( cx + x * alpha - y * beta );
pt.y = cvRound( cy + x * beta + y * alpha ); pt.y = cvRound( cy + x * beta + y * alpha );
if( pt != prevPt ) if( pt != prevPt ){
pts.push_back(pt); pts.push_back(pt);
prevPt = pt;
}
} }
if( pts.size() < 2 ) if( pts.size() == 1 )
pts.push_back(pts[0]); pts.push_back(pts[0]);
} }
......
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