PCBNew - fix incorrect gerber generation for overlapping zones of the same net and having different draw options.

Previously, zones of the same net were merged for plotting,
regardless the fact the outline thickness can be different between the zones,
creating incorrect solid areas.

Fixes: lp:1840695
https://bugs.launchpad.net/kicad/+bug/1840695
This commit is contained in:
jean-pierre charras
2019-08-25 13:16:45 +02:00
parent 9f80da60c3
commit a0fec9db57
2 changed files with 18 additions and 6 deletions
+4 -5
View File
@@ -659,12 +659,13 @@ void BRDITEMS_PLOTTER::PlotFilledAreas( ZONE_CONTAINER* aZone, SHAPE_POLY_SET& p
m_plotter->SetColor( getColor( aZone->GetLayer() ) );
/* Plot all filled areas: filled areas have a filled area and a thick
* outline we must plot the filled area itself ( as a filled polygon
* OR a set of segments ) and plot the thick outline itself,
* if the thickness has meaning (at least is > 1)
* outline (depending on the fill area option we must plot the filled area itself
* and plot the thick outline itself, if the thickness has meaning (at least is > 1)
*
* in non filled mode the outline is plotted, but not the filling items
*/
int outline_thickness = aZone->GetFilledPolysUseThickness() ? aZone->GetMinThickness() : 0;
for( auto ic = polysList.CIterate(); ic; ++ic )
{
wxPoint pos( ic->x, ic->y );
@@ -677,8 +678,6 @@ void BRDITEMS_PLOTTER::PlotFilledAreas( ZONE_CONTAINER* aZone, SHAPE_POLY_SET& p
cornerList.push_back( cornerList[0] );
// Plot the current filled area and its outline
int outline_thickness = aZone->GetFilledPolysUseThickness() ? aZone->GetMinThickness() : 0;
if( GetPlotMode() == FILLED )
{
m_plotter->PlotPoly( cornerList, FILLED_SHAPE, outline_thickness, &gbr_metadata );