Remove work-around in favour of real fix in Clipper.
This commit is contained in:
parent
19deb7051a
commit
791a50b493
|
@ -604,10 +604,6 @@ void SHAPE_POLY_SET::Inflate( int aAmount, int aCircleSegmentsCount,
|
||||||
if( aCircleSegmentsCount < 6 ) // avoid incorrect aCircleSegmentsCount values
|
if( aCircleSegmentsCount < 6 ) // avoid incorrect aCircleSegmentsCount values
|
||||||
aCircleSegmentsCount = 6;
|
aCircleSegmentsCount = 6;
|
||||||
|
|
||||||
// Clipper has a bug where round-off error is accumulated into the last segment. Increasing
|
|
||||||
// the segment count by one probably accounts for this, but we increment by 2 to be safe.
|
|
||||||
aCircleSegmentsCount += 2;
|
|
||||||
|
|
||||||
double coeff;
|
double coeff;
|
||||||
|
|
||||||
if( aCircleSegmentsCount > SEG_CNT_MAX || arc_tolerance_factor[aCircleSegmentsCount] == 0 )
|
if( aCircleSegmentsCount > SEG_CNT_MAX || arc_tolerance_factor[aCircleSegmentsCount] == 0 )
|
||||||
|
|
|
@ -5458,6 +5458,10 @@ void ClipperOffset::DoRound( int j, int k )
|
||||||
Y = X2 * m_sin + Y * m_cos;
|
Y = X2 * m_sin + Y * m_cos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
m_destPoly.push_back( IntPoint(
|
||||||
|
Round( m_srcPoly[j].X + X * m_delta ),
|
||||||
|
Round( m_srcPoly[j].Y + Y * m_delta ) ) );
|
||||||
|
|
||||||
m_destPoly.push_back( IntPoint(
|
m_destPoly.push_back( IntPoint(
|
||||||
Round( m_srcPoly[j].X + m_normals[j].X * m_delta ),
|
Round( m_srcPoly[j].X + m_normals[j].X * m_delta ),
|
||||||
Round( m_srcPoly[j].Y + m_normals[j].Y * m_delta ) ) );
|
Round( m_srcPoly[j].Y + m_normals[j].Y * m_delta ) ) );
|
||||||
|
|
Loading…
Reference in New Issue