Don't register DRC error on internal approximation

Users can set the internal approximation of curves, which will create
small errors off of ideal locations.  This will cause DRC errors on some
items such as rounded rect pads when elements are routed at the minimum
ideal distance.  Users could already tune this value using the Advanced
Config values but we'd rather the user not depend on that.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/9833
This commit is contained in:
Seth Hillbrand 2021-11-30 15:25:33 -08:00
parent d64ae52042
commit 5dcd6f89d3
1 changed files with 3 additions and 1 deletions

View File

@ -1116,7 +1116,9 @@ int BOARD_DESIGN_SETTINGS::GetLayerClass( PCB_LAYER_ID aLayer ) const
int BOARD_DESIGN_SETTINGS::GetDRCEpsilon() const int BOARD_DESIGN_SETTINGS::GetDRCEpsilon() const
{ {
return Millimeter2iu( ADVANCED_CFG::GetCfg().m_DRCEpsilon ); // You can loosen the max epsilon manually but we cap it at the board's inherent
// accuracy given by the maximum error when approximating curves
return std::max( m_MaxError, Millimeter2iu( ADVANCED_CFG::GetCfg().m_DRCEpsilon ) );
} }