diff --git a/pcbnew/router/pns_node.cpp b/pcbnew/router/pns_node.cpp index e05bdca8e6..8237a35f8a 100644 --- a/pcbnew/router/pns_node.cpp +++ b/pcbnew/router/pns_node.cpp @@ -947,16 +947,25 @@ const LINE NODE::AssembleLine( LINKED_ITEM* aSeg, int* aOriginSegmentIndex, const VECTOR2I& p = corners[i]; LINKED_ITEM* li = segs[i]; + int nsegs = pl.Line().SegmentCount(); + if( !li || li->Kind() != ITEM::ARC_T ) pl.Line().Append( p ); if( li && prev_seg != li ) { + int segIdxIncrement = 1; + if( li->Kind() == ITEM::ARC_T ) { const ARC* arc = static_cast( li ); const SHAPE_ARC* sa = static_cast( arc->Shape() ); + + int nSegs = pl.Line().SegmentCount(); + pl.Line().Append( arcReversed[i] ? sa->Reversed() : *sa ); + + segIdxIncrement = pl.Line().SegmentCount() - nSegs - 1; } pl.Link( li ); @@ -968,7 +977,7 @@ const LINE NODE::AssembleLine( LINKED_ITEM* aSeg, int* aOriginSegmentIndex, originSet = true; } - n++; + n += segIdxIncrement; } prev_seg = li; diff --git a/pcbnew/router/pns_shove.cpp b/pcbnew/router/pns_shove.cpp index 98ed3121ad..3035ea1f1d 100644 --- a/pcbnew/router/pns_shove.cpp +++ b/pcbnew/router/pns_shove.cpp @@ -533,7 +533,7 @@ SHOVE::SHOVE_STATUS SHOVE::onCollidingLine( LINE& aCurrent, LINE& aObstacle ) Dbg()->AddLine( aObstacle.CLine(), 1, 100000, "obstacle-line" ); Dbg()->AddLine( aCurrent.CLine(), 2, 150000, "current-line" ); Dbg()->AddLine( shovedLine.CLine(), 3, 200000, "shoved-line" ); - + if( rv == SH_OK ) { if( shovedLine.Marker() & MK_HEAD ) @@ -1301,7 +1301,7 @@ SHOVE::SHOVE_STATUS SHOVE::ShoveLines( const LINE& aCurrentHead ) m_multiLineMode = false; if( Dbg() ) - { + { Dbg()->Message( wxString::Format( "Shove start, lc = %d", aCurrentHead.SegmentCount() ) ); }