3D viewer: show "not covered by solder mask" graphic items with the right color.

Previously, only pads and tracks were using the gold color when not covered by
the solder mask layer.
Fixes #16892
https://gitlab.com/kicad/code/kicad/-/issues/16892
This commit is contained in:
jean-pierre charras 2024-02-09 11:34:27 +01:00
parent 3c45145401
commit 4c61a79e47
1 changed files with 12 additions and 1 deletions

View File

@ -3,7 +3,7 @@
* *
* Copyright (C) 2015-2016 Mario Luzeiro <mrluzeiro@ua.pt> * Copyright (C) 2015-2016 Mario Luzeiro <mrluzeiro@ua.pt>
* Copyright (C) 2023 CERN * Copyright (C) 2023 CERN
* Copyright (C) 1992-2023 KiCad Developers, see AUTHORS.txt for contributors. * Copyright (C) 1992-2024 KiCad Developers, see AUTHORS.txt for contributors.
* *
* This program is free software; you can redistribute it and/or * This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License * modify it under the terms of the GNU General Public License
@ -635,6 +635,17 @@ void BOARD_ADAPTER::createLayers( REPORTER* aStatusReporter )
item->Type() ); item->Type() );
break; break;
} }
// add also this shape to the plated copper polygon list if required
if( cfg.differentiate_plated_copper )
{
if( layer == F_Cu )
item->TransformShapeToPolygon( *m_frontPlatedCopperPolys, F_Cu,
0, maxError, ERROR_INSIDE );
else if( layer == B_Cu )
item->TransformShapeToPolygon( *m_backPlatedCopperPolys, B_Cu,
0, maxError, ERROR_INSIDE );
}
} }
} }