From 9fc7281fab26a7efdee4a21930f85192a0f5b2a1 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Wed, 10 Apr 2019 17:49:40 +0200 Subject: [PATCH] Zone filler: fix missing calculation of filled polygons when fill mode is ZFM::SEGMENTS --- pcbnew/zone_filler.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/pcbnew/zone_filler.cpp b/pcbnew/zone_filler.cpp index 14df295539..aabcbc7bd4 100644 --- a/pcbnew/zone_filler.cpp +++ b/pcbnew/zone_filler.cpp @@ -131,6 +131,11 @@ bool ZONE_FILLER::Fill( std::vector aZones, bool aCheck ) for( size_t i = nextItem++; i < toFill.size(); i = nextItem++ ) { ZONE_CONTAINER* zone = toFill[i].m_zone; + SHAPE_POLY_SET rawPolys, finalPolys; + fillSingleZone( zone, rawPolys, finalPolys ); + + zone->SetRawPolysList( rawPolys ); + zone->SetFilledPolysList( finalPolys ); if( zone->GetFillMode() == ZFM_SEGMENTS ) { @@ -138,14 +143,6 @@ bool ZONE_FILLER::Fill( std::vector aZones, bool aCheck ) fillZoneWithSegments( zone, zone->GetFilledPolysList(), segFill ); zone->SetFillSegments( segFill ); } - else - { - SHAPE_POLY_SET rawPolys, finalPolys; - fillSingleZone( zone, rawPolys, finalPolys ); - - zone->SetRawPolysList( rawPolys ); - zone->SetFilledPolysList( finalPolys ); - } zone->SetIsFilled( true );