Use lower error limit where appropriate.

In both these cases we're just checking for a well-formed
outline.  We don't use the resulting poly.
This commit is contained in:
Jeff Young
2025-05-12 20:28:47 +01:00
parent 9ec4c9f540
commit a65534a337
2 changed files with 12 additions and 10 deletions
+8 -8
View File
@@ -585,15 +585,15 @@ void DIALOG_EXPORT_STEP::onExportButton( wxCommandEvent& aEvent )
// max dist from one endPt to next startPt to build a closed shape:
int chainingEpsilon = pcbIUScale.mmToIU( tolerance );
// Arc to segment approx error (not critical here: we do not use the outline shape):
int maxError = pcbIUScale.mmToIU( 0.005 );
bool success = BuildBoardPolygonOutlines( m_editFrame->GetBoard(), outline, maxError,
chainingEpsilon, nullptr );
if( !success )
// Arc to segment approximation error (not critical here: we do not use the outline shape):
int maxError = pcbIUScale.mmToIU( 0.05 );
if( !BuildBoardPolygonOutlines( m_editFrame->GetBoard(), outline, maxError, chainingEpsilon ) )
{
DisplayErrorMessage( this, wxString::Format(
_( "Board outline is missing or not closed using %.3f mm tolerance.\n"
"Run DRC for a full analysis." ), tolerance ) );
DisplayErrorMessage( this, wxString::Format( _( "Board outline is missing or not closed using "
"%.3f mm tolerance.\n"
"Run DRC for a full analysis." ),
tolerance ) );
return;
}
+4 -2
View File
@@ -132,8 +132,10 @@ void DRC_TEST_PROVIDER_MISC::testOutline()
// other tools (such as 3D viewer).
int chainingEpsilon = m_board->GetOutlinesChainingEpsilon();
if( !BuildBoardPolygonOutlines( m_board, dummyOutline, m_board->GetDesignSettings().m_MaxError,
chainingEpsilon, &errorHandler ) )
// Arc to segment approximation error (not critical here: we do not use the outline shape):
int maxError = pcbIUScale.mmToIU( 0.05 );
if( !BuildBoardPolygonOutlines( m_board, dummyOutline, maxError, chainingEpsilon, &errorHandler ) )
{
if( errorHandled )
{