From aa53b5508e1fc14aeae267c15ea574b790600cba 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 000b1d0c4e..b0a00f9921 100644 --- a/pcbnew/zone_filler.cpp +++ b/pcbnew/zone_filler.cpp @@ -127,6 +127,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 ) { @@ -134,14 +139,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 );