Handle non-cardinal major-axis arcs when importing DXF.
This commit is contained in:
parent
eba8acf602
commit
a946f7ab1b
|
@ -645,7 +645,9 @@ void DXF_IMPORT_PLUGIN::addEllipse( const DL_EllipseData& aData )
|
|||
if( startAngle > endAngle )
|
||||
endAngle += ANGLE_360;
|
||||
|
||||
// TODO: testcases for negative extrusion vector; handle it here
|
||||
// Angles are relative to major axis
|
||||
startAngle -= EDA_ANGLE( major );
|
||||
endAngle -= EDA_ANGLE( major );
|
||||
|
||||
if( aData.ratio == 1.0 )
|
||||
{
|
||||
|
@ -666,6 +668,8 @@ void DXF_IMPORT_PLUGIN::addEllipse( const DL_EllipseData& aData )
|
|||
}
|
||||
}
|
||||
|
||||
// TODO: testcases for negative extrusion vector; handle it here
|
||||
|
||||
std::vector<BEZIER<double>> splines;
|
||||
ELLIPSE<double> ellipse( center, major, aData.ratio, startAngle, endAngle );
|
||||
|
||||
|
|
Loading…
Reference in New Issue