Allow specifying acuracy when appending an arc to a chain
This commit is contained in:
parent
ee6e86d1db
commit
ebce53d574
|
@ -529,6 +529,7 @@ public:
|
|||
void Append( const SHAPE_LINE_CHAIN& aOtherLine );
|
||||
|
||||
void Append( const SHAPE_ARC& aArc );
|
||||
void Append( const SHAPE_ARC& aArc, double aAccuracy );
|
||||
|
||||
void Insert( size_t aVertex, const VECTOR2I& aP );
|
||||
|
||||
|
|
|
@ -1324,6 +1324,12 @@ void SHAPE_LINE_CHAIN::Append( const SHAPE_LINE_CHAIN& aOtherLine )
|
|||
|
||||
|
||||
void SHAPE_LINE_CHAIN::Append( const SHAPE_ARC& aArc )
|
||||
{
|
||||
Append( aArc, SHAPE_ARC::DefaultAccuracyForPCB() );
|
||||
}
|
||||
|
||||
|
||||
void SHAPE_LINE_CHAIN::Append( const SHAPE_ARC& aArc, double aAccuracy )
|
||||
{
|
||||
SEG startToEnd( aArc.GetP0(), aArc.GetP1() );
|
||||
|
||||
|
@ -1335,7 +1341,7 @@ void SHAPE_LINE_CHAIN::Append( const SHAPE_ARC& aArc )
|
|||
}
|
||||
else
|
||||
{
|
||||
SHAPE_LINE_CHAIN chain = aArc.ConvertToPolyline();
|
||||
SHAPE_LINE_CHAIN chain = aArc.ConvertToPolyline( aAccuracy );
|
||||
|
||||
// @todo should the below 4 LOC be moved to SHAPE_ARC::ConvertToPolyline ?
|
||||
chain.m_arcs.push_back( aArc );
|
||||
|
|
Loading…
Reference in New Issue