bugfix #1323135: PNS creates vias with giant holes.
This commit is contained in:
parent
e585f2d205
commit
b9246dd463
|
@ -380,8 +380,7 @@ bool PNS_LINE_PLACER::handleViaPlacement( PNS_LINE& aHead )
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
PNS_LAYERSET allLayers( 0, 15 );
|
PNS_LAYERSET allLayers( 0, 15 );
|
||||||
PNS_VIA v( aHead.CPoint( -1 ), allLayers, m_viaDiameter, aHead.Net() );
|
PNS_VIA v( aHead.CPoint( -1 ), allLayers, m_viaDiameter, m_viaDrill, aHead.Net() );
|
||||||
v.SetDrill( m_viaDrill );
|
|
||||||
|
|
||||||
VECTOR2I force;
|
VECTOR2I force;
|
||||||
VECTOR2I lead = aHead.CPoint( -1 ) - aHead.CPoint( 0 );
|
VECTOR2I lead = aHead.CPoint( -1 ) - aHead.CPoint( 0 );
|
||||||
|
@ -441,7 +440,7 @@ bool PNS_LINE_PLACER::rhWalkOnly ( const VECTOR2I& aP, PNS_LINE& aNewHead )
|
||||||
else if( m_placingVia && viaOk )
|
else if( m_placingVia && viaOk )
|
||||||
{
|
{
|
||||||
PNS_LAYERSET allLayers( 0, 15 );
|
PNS_LAYERSET allLayers( 0, 15 );
|
||||||
PNS_VIA v1( walkFull.CPoint( -1 ), allLayers, m_viaDiameter );
|
PNS_VIA v1( walkFull.CPoint( -1 ), allLayers, m_viaDiameter, m_viaDrill );
|
||||||
walkFull.AppendVia( v1 );
|
walkFull.AppendVia( v1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -466,7 +465,7 @@ bool PNS_LINE_PLACER::rhMarkObstacles( const VECTOR2I& aP, PNS_LINE& aNewHead )
|
||||||
if( m_placingVia )
|
if( m_placingVia )
|
||||||
{
|
{
|
||||||
PNS_LAYERSET allLayers( 0, 15 );
|
PNS_LAYERSET allLayers( 0, 15 );
|
||||||
PNS_VIA v1( m_head.CPoint( -1 ), allLayers, m_viaDiameter );
|
PNS_VIA v1( m_head.CPoint( -1 ), allLayers, m_viaDiameter, m_viaDrill );
|
||||||
m_head.AppendVia( v1 );
|
m_head.AppendVia( v1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -509,10 +508,8 @@ bool PNS_LINE_PLACER::rhShoveOnly ( const VECTOR2I& aP, PNS_LINE& aNewHead )
|
||||||
if( m_placingVia )
|
if( m_placingVia )
|
||||||
{
|
{
|
||||||
PNS_LAYERSET allLayers( 0, 15 );
|
PNS_LAYERSET allLayers( 0, 15 );
|
||||||
PNS_VIA v1( l.CPoint( -1 ), allLayers, m_viaDiameter );
|
PNS_VIA v1( l.CPoint( -1 ), allLayers, m_viaDiameter, m_viaDrill );
|
||||||
PNS_VIA v2( l2.CPoint( -1 ), allLayers, m_viaDiameter );
|
PNS_VIA v2( l2.CPoint( -1 ), allLayers, m_viaDiameter, m_viaDrill );
|
||||||
v1.SetDrill( m_viaDrill );
|
|
||||||
v2.SetDrill( m_viaDrill );
|
|
||||||
|
|
||||||
l.AppendVia( v1 );
|
l.AppendVia( v1 );
|
||||||
l2.AppendVia( v2 );
|
l2.AppendVia( v2 );
|
||||||
|
|
|
@ -35,13 +35,15 @@ public:
|
||||||
PNS_ITEM( VIA )
|
PNS_ITEM( VIA )
|
||||||
{}
|
{}
|
||||||
|
|
||||||
PNS_VIA( const VECTOR2I& aPos, const PNS_LAYERSET& aLayers, int aDiameter, int aNet = -1 ) :
|
PNS_VIA( const VECTOR2I& aPos, const PNS_LAYERSET& aLayers,
|
||||||
|
int aDiameter, int aDrill, int aNet = -1 ) :
|
||||||
PNS_ITEM( VIA )
|
PNS_ITEM( VIA )
|
||||||
{
|
{
|
||||||
SetNet( aNet );
|
SetNet( aNet );
|
||||||
SetLayers( aLayers );
|
SetLayers( aLayers );
|
||||||
m_pos = aPos;
|
m_pos = aPos;
|
||||||
m_diameter = aDiameter;
|
m_diameter = aDiameter;
|
||||||
|
m_drill = aDrill;
|
||||||
m_shape = SHAPE_CIRCLE( aPos, aDiameter / 2 );
|
m_shape = SHAPE_CIRCLE( aPos, aDiameter / 2 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue