void GERBER_PLOTTER::selectAperture( const wxSize& size, APERTURE::APERTURE_TYPE type ) { wxASSERT( outputFile ); if( ( currentAperture == apertures.end() ) || ( currentAperture->Type != type ) || ( currentAperture->Size != size ) ) { // Pick an existing aperture or create a new one currentAperture = getAperture( size, type ); fprintf( outputFile, "D%d*\n", currentAperture->DCode ); } }
void GERBER_PLOTTER::selectAperture( const wxSize& aSize, APERTURE::APERTURE_TYPE aType, int aApertureAttribute ) { bool change = ( currentAperture == apertures.end() ) || ( currentAperture->m_Type != aType ) || ( currentAperture->m_Size != aSize ); if( m_useX2Attributes && !m_useNetAttributes ) aApertureAttribute = 0; else change = change || ( currentAperture->m_ApertureAttribute != aApertureAttribute ); if( change ) { // Pick an existing aperture or create a new one currentAperture = getAperture( aSize, aType, aApertureAttribute ); fprintf( outputFile, "D%d*\n", currentAperture->m_DCode ); } }