KiCad PCB EDA Suite
|
Single track placement algorithm. More...
#include <pns_diff_pair_placer.h>
Public Member Functions | |
DIFF_PAIR_PLACER (ROUTER *aRouter) | |
~DIFF_PAIR_PLACER () | |
bool | Start (const VECTOR2I &aP, ITEM *aStartItem) override |
Start routing a single track at point aP, taking item aStartItem as anchor (unless NULL). | |
bool | Move (const VECTOR2I &aP, ITEM *aEndItem) override |
Move the end of the currently routed trace to the point aP, taking aEndItem as anchor (if not NULL). | |
bool | FixRoute (const VECTOR2I &aP, ITEM *aEndItem, bool aForceFinish) override |
Commit the currently routed track to the parent node, taking aP as the final end point and aEndItem as the final anchor (if provided). | |
bool | CommitPlacement () override |
bool | AbortPlacement () override |
bool | HasPlacedAnything () const override |
bool | ToggleVia (bool aEnabled) override |
Enable/disable a via at the end of currently routed trace. | |
bool | SetLayer (int aLayer) override |
Set the current routing layer. | |
const ITEM_SET | Traces () override |
Return the complete routed line, as a single-member ITEM_SET. | |
const VECTOR2I & | CurrentStart () const override |
Return the current start of the line being placed. | |
const VECTOR2I & | CurrentEnd () const override |
Return the current end of the line being placed. | |
const std::vector< NET_HANDLE > | CurrentNets () const override |
Return the net of currently routed track. | |
int | CurrentLayer () const override |
Return the layer of currently routed track. | |
NODE * | CurrentNode (bool aLoopsRemoved=false) const override |
Return the most recent world state. | |
void | FlipPosture () override |
Toggle the current posture (straight/diagonal) of the trace head. | |
void | UpdateSizes (const SIZES_SETTINGS &aSizes) override |
Perform on-the-fly update of the width, via diameter & drill size from a settings class. | |
bool | IsPlacingVia () const override |
Function IsPlacingVia() | |
void | SetOrthoMode (bool aOrthoMode) override |
Function SetOrthoMode() | |
void | GetModifiedNets (std::vector< NET_HANDLE > &aNets) const override |
Function GetModifiedNets. | |
virtual std::optional< VECTOR2I > | UnfixRoute () |
ROUTER * | Router () const |
Return current router settings. | |
ROUTING_SETTINGS & | Settings () const |
Return the logger object, allowing to dump geometry to a file. | |
virtual LOGGER * | Logger () |
void | SetLogger (LOGGER *aLogger) |
void | SetDebugDecorator (DEBUG_DECORATOR *aDecorator) |
Assign a debug decorator allowing this algo to draw extra graphics for visual debugging. | |
DEBUG_DECORATOR * | Dbg () const |
const BOX2I & | VisibleViewArea () const |
Static Public Member Functions | |
static bool | FindDpPrimitivePair (NODE *aWorld, const VECTOR2I &aP, ITEM *aItem, DP_PRIMITIVE_PAIR &aPair, wxString *aErrorMsg=nullptr) |
Protected Attributes | |
DEBUG_DECORATOR * | m_debugDecorator |
ROUTER * | m_router |
LOGGER * | m_logger |
Private Types | |
enum | State { RT_START = 0 , RT_ROUTE = 1 , RT_FINISH = 2 } |
Private Member Functions | |
int | viaGap () const |
int | gap () const |
bool | route (const VECTOR2I &aP) |
Re-route the current track to point aP. | |
void | updateLeadingRatLine () |
Draw the "leading" ratsnest line, which connects the end of currently routed track and the nearest yet unrouted item. | |
void | setWorld (NODE *aWorld) |
Set the board to route. | |
void | initPlacement () |
Initialize placement of a new line with given parameters. | |
void | setInitialDirection (const DIRECTION_45 &aDirection) |
Set preferred direction of the very first track segment to be laid. | |
bool | routeHead (const VECTOR2I &aP) |
bool | tryWalkDp (NODE *aNode, DIFF_PAIR &aPair, bool aSolidsOnly) |
route step, walk around mode | |
bool | rhWalkOnly (const VECTOR2I &aP) |
route step, shove mode | |
bool | rhShoveOnly (const VECTOR2I &aP) |
route step, mark obstacles mode | |
bool | rhMarkObstacles (const VECTOR2I &aP) |
const VIA | makeVia (const VECTOR2I &aP, NET_HANDLE aNet) |
bool | attemptWalk (NODE *aNode, DIFF_PAIR *aCurrent, DIFF_PAIR &aWalk, bool aPFirst, bool aWindCw, bool aSolidsOnly) |
bool | propagateDpHeadForces (const VECTOR2I &aP, VECTOR2I &aNewP) |
Private Attributes | |
State | m_state |
bool | m_chainedPlacement |
bool | m_initialDiagonal |
bool | m_startDiagonal |
bool | m_fitOk |
NET_HANDLE | m_netP |
NET_HANDLE | m_netN |
DP_PRIMITIVE_PAIR | m_start |
std::optional< DP_PRIMITIVE_PAIR > | m_prevPair |
current algorithm iteration | |
int | m_iteration |
pointer to world to search colliding items | |
NODE * | m_world |
current routing start point (end of tail, beginning of head) | |
VECTOR2I | m_p_start |
The shove engine. | |
std::unique_ptr< SHOVE > | m_shove |
Current world state. | |
NODE * | m_currentNode |
Postprocessed world state (including marked collisions & removed loops) | |
NODE * | m_lastNode |
SIZES_SETTINGS | m_sizes |
Are we placing a via? | |
bool | m_placingVia |
current via diameter | |
int | m_viaDiameter |
current via drill | |
int | m_viaDrill |
current track width | |
int | m_currentWidth |
int | m_currentLayer |
bool | m_startsOnVia |
bool | m_orthoMode |
bool | m_snapOnTarget |
VECTOR2I | m_currentEnd |
VECTOR2I | m_currentStart |
DIFF_PAIR | m_currentTrace |
bool | m_currentTraceOk |
ITEM * | m_currentEndItem |
bool | m_idle |
Single track placement algorithm.
Interactively routes a track and applies shove and walk around algorithms when needed.
Definition at line 52 of file pns_diff_pair_placer.h.
|
private |
Enumerator | |
---|---|
RT_START | |
RT_ROUTE | |
RT_FINISH |
Definition at line 217 of file pns_diff_pair_placer.h.
PNS::DIFF_PAIR_PLACER::DIFF_PAIR_PLACER | ( | ROUTER * | aRouter | ) |
Definition at line 33 of file pns_diff_pair_placer.cpp.
References m_chainedPlacement, m_currentEndItem, m_currentLayer, m_currentNode, m_currentTraceOk, m_currentWidth, m_fitOk, m_idle, m_initialDiagonal, m_iteration, m_lastNode, m_netN, m_netP, m_orthoMode, m_placingVia, m_shove, m_snapOnTarget, m_startDiagonal, m_startsOnVia, m_state, m_viaDiameter, m_viaDrill, m_world, and RT_START.
PNS::DIFF_PAIR_PLACER::~DIFF_PAIR_PLACER | ( | ) |
Definition at line 61 of file pns_diff_pair_placer.cpp.
|
overridevirtual |
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 848 of file pns_diff_pair_placer.cpp.
References PNS::NODE::KillChildren(), and m_world.
|
private |
Definition at line 197 of file pns_diff_pair_placer.cpp.
References PNS::ITEM::ANY_T, PNS::NODE::CheckColliding(), PNS::LINE::CLine(), PNS::DIFF_PAIR::CN(), PNS::DIFF_PAIR::CP(), PNS::SHOVE::ForceClearance(), PNS::DIFF_PAIR::Gap(), PNS::LINE::Line(), PNS::DIFF_PAIR::NLine(), PNS::DIFF_PAIR::PLine(), PNS_HULL_MARGIN, PNS::WALKAROUND::Route(), PNS::ALGO_BASE::Router(), PNS::WALKAROUND::SetAllowedPolicies(), PNS::WALKAROUND::SetIterationLimit(), PNS::DIFF_PAIR::SetShape(), PNS::WALKAROUND::SetSolidsOnly(), PNS::ALGO_BASE::Settings(), PNS::SHOVE::ShoveObstacleLine(), SHAPE_LINE_CHAIN::Simplify(), PNS::ITEM::SOLID_T, PNS::WALKAROUND::ST_DONE, and PNS::WALKAROUND::WP_SHORTEST.
Referenced by tryWalkDp().
|
overridevirtual |
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 861 of file pns_diff_pair_placer.cpp.
References PNS::ROUTER::CommitRouting(), m_currentNode, m_lastNode, and PNS::ALGO_BASE::Router().
Referenced by FixRoute().
|
inlineoverridevirtual |
Return the current end of the line being placed.
It may not be equal to the cursor position due to collisions.
Implements PNS::PLACEMENT_ALGO.
Definition at line 118 of file pns_diff_pair_placer.h.
References m_currentEnd.
|
inlineoverridevirtual |
Return the layer of currently routed track.
Implements PNS::PLACEMENT_ALGO.
Definition at line 131 of file pns_diff_pair_placer.h.
References m_currentLayer.
|
overridevirtual |
Return the net of currently routed track.
Implements PNS::PLACEMENT_ALGO.
Definition at line 892 of file pns_diff_pair_placer.cpp.
|
overridevirtual |
Return the most recent world state.
Implements PNS::PLACEMENT_ALGO.
Definition at line 411 of file pns_diff_pair_placer.cpp.
References m_currentNode, and m_lastNode.
|
inlineoverridevirtual |
Return the current start of the line being placed.
Implements PNS::PLACEMENT_ALGO.
Definition at line 109 of file pns_diff_pair_placer.h.
References m_currentStart.
|
inlineinherited |
Definition at line 78 of file pns_algo_base.h.
References PNS::ALGO_BASE::m_debugDecorator.
Referenced by PNS::SHOVE::AddLockedSpringbackNode(), PNS::LINE_PLACER::buildInitialLine(), PNS::LINE_PLACER::clipAndCheckCollisions(), PNS::MEANDER_PLACER::doMove(), PNS::COMPONENT_DRAGGER::Drag(), PNS::MULTI_DRAGGER::Drag(), PNS::DRAGGER::dragShove(), PNS::DRAGGER::dragWalkaround(), PNS::MULTI_DRAGGER::findNewLeaderSegment(), PNS::SHOVE::fixupViaCollisions(), PNS::LINE_PLACER::handlePullback(), PNS::LINE_PLACER::mergeHead(), PNS::DP_MEANDER_PLACER::Move(), PNS::MEANDER_SKEW_PLACER::Move(), PNS::MULTI_DRAGGER::multidragShove(), PNS::MULTI_DRAGGER::multidragWalkaround(), PNS::SHOVE::onCollidingArc(), PNS::SHOVE::onCollidingLine(), PNS::SHOVE::onCollidingSegment(), PNS::SHOVE::onCollidingSolid(), PNS::SHOVE::onCollidingVia(), PNS::SHOVE::onReverseCollidingVia(), PNS::DRAGGER::optimizeAndUpdateDraggedLine(), PNS::LINE_PLACER::optimizeTailHeadTransition(), PNS::SHOVE::preShoveCleanup(), PNS::SHOVE::pruneRootLines(), PNS::SHOVE::pushLineStack(), PNS::SHOVE::pushOrShoveVia(), PNS::SHOVE::pushSpringback(), PNS::SHOVE::reconstructHeads(), PNS::SHOVE::reduceSpringback(), PNS::LINE_PLACER::reduceTail(), PNS::SHOVE::removeHeads(), PNS::LINE_PLACER::removeLoops(), PNS::SHOVE::replaceItems(), PNS::SHOVE::replaceLine(), PNS::LINE_PLACER::rhShoveOnly(), PNS::LINE_PLACER::rhWalkBase(), PNS::LINE_PLACER::rhWalkOnly(), PNS::WALKAROUND::Route(), PNS::LINE_PLACER::routeStep(), PNS::SHOVE::Run(), PNS::SHOVE::runOptimizer(), PNS::SHOVE::shoveIteration(), PNS::SHOVE::shoveLineToHullSet(), PNS::SHOVE::shoveMainLoop(), PNS::SHOVE::ShoveObstacleLine(), PNS::WALKAROUND::singleStep(), PNS::LINE_PLACER::splitHeadTail(), PNS::LINE_PLACER::Start(), PNS::DRAGGER::Start(), PNS::MULTI_DRAGGER::Start(), PNS::SHOVE::touchRootLine(), PNS::LINE_PLACER::Trace(), PNS::DRAGGER::tryWalkaround(), PNS::MULTI_DRAGGER::tryWalkaround(), and PNS::SHOVE::unwindLineStack().
|
static |
Definition at line 498 of file pns_diff_pair_placer.cpp.
References _, PNS::NODE::AllItemsInNet(), anchor, PNS::RULE_RESOLVER::DpNetPair(), PNS::getDanglingAnchor(), PNS::NODE::GetRuleResolver(), PNS::ITEM::Kind(), PNS::ITEM::Layers(), PNS::ITEM::Net(), PNS::RULE_RESOLVER::NetName(), PNS::DP_PRIMITIVE_PAIR::SetAnchors(), PNS::ITEM::SOLID_T, and PNS::ITEM::VIA_T.
Referenced by PNS::ROUTER::isStartingPointRoutable(), routeHead(), and Start().
|
overridevirtual |
Commit the currently routed track to the parent node, taking aP as the final end point and aEndItem as the final anchor (if provided).
Implements PNS::PLACEMENT_ALGO.
Definition at line 782 of file pns_diff_pair_placer.cpp.
References PNS::NODE::Add(), PNS::Clone(), PNS::DIFF_PAIR::CN(), CommitPlacement(), PNS::DIFF_PAIR::CP(), SHAPE_LINE_CHAIN::CSegment(), PNS::DIFF_PAIR::EndingPrimitives(), PNS::DIFF_PAIR::EndsWithVias(), initPlacement(), DIRECTION_45::IsDiagonal(), m_chainedPlacement, m_currentTrace, m_fitOk, m_idle, m_initialDiagonal, m_lastNode, m_placingVia, m_prevPair, m_snapOnTarget, PNS::DIFF_PAIR::NLine(), PNS::DIFF_PAIR::PLine(), SHAPE_LINE_CHAIN::Remove(), SHAPE_LINE_CHAIN::SegmentCount(), PNS::DIFF_PAIR::SetShape(), PNS::ALGO_BASE::Settings(), PNS::TOPOLOGY::SimplifyLine(), and PNS::LINE::Via().
|
overridevirtual |
Toggle the current posture (straight/diagonal) of the trace head.
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 402 of file pns_diff_pair_placer.cpp.
References m_currentEnd, m_idle, m_startDiagonal, and Move().
|
private |
Definition at line 600 of file pns_diff_pair_placer.cpp.
References PNS::SIZES_SETTINGS::DiffPairGap(), PNS::SIZES_SETTINGS::DiffPairWidth(), and m_sizes.
Referenced by routeHead().
|
overridevirtual |
Function GetModifiedNets.
Returns the nets of all currently routed trace(s)
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 872 of file pns_diff_pair_placer.cpp.
|
overridevirtual |
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 855 of file pns_diff_pair_placer.cpp.
References PNS::DIFF_PAIR::CN(), PNS::DIFF_PAIR::CP(), m_currentTrace, and SHAPE_LINE_CHAIN::SegmentCount().
|
private |
Initialize placement of a new line with given parameters.
Definition at line 638 of file pns_diff_pair_placer.cpp.
References PNS::NODE::Branch(), PNS::ROUTER::GetWorld(), PNS::NODE::KillChildren(), m_currentEndItem, m_currentNode, m_idle, m_initialDiagonal, m_lastNode, m_orthoMode, m_shove, m_startDiagonal, PNS::ALGO_BASE::Router(), and setWorld().
Referenced by FixRoute(), SetLayer(), and Start().
|
inlineoverridevirtual |
Function IsPlacingVia()
Returns true if the placer is placing a via (or more vias).
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 153 of file pns_diff_pair_placer.h.
References m_placingVia.
|
virtualinherited |
Definition at line 34 of file pns_algo_base.cpp.
References PNS::ALGO_BASE::m_logger.
Referenced by PNS::LINE_PLACER::rhShoveOnly(), PNS::LINE_PLACER::rhWalkBase(), PNS::DRAGGER::Start(), PNS::MULTI_DRAGGER::Start(), PNS::DRAGGER::tryWalkaround(), and PNS::MULTI_DRAGGER::tryWalkaround().
|
private |
Definition at line 71 of file pns_diff_pair_placer.cpp.
References PNS::SIZES_SETTINGS::GetLayerBottom(), PNS::SIZES_SETTINGS::GetLayerTop(), m_sizes, PNS::SIZES_SETTINGS::ViaDiameter(), PNS::SIZES_SETTINGS::ViaDrill(), and PNS::SIZES_SETTINGS::ViaType().
Referenced by propagateDpHeadForces(), and routeHead().
Move the end of the currently routed trace to the point aP, taking aEndItem as anchor (if not NULL).
Implements PNS::PLACEMENT_ALGO.
Definition at line 742 of file pns_diff_pair_placer.cpp.
References PNS::NODE::Branch(), m_currentEnd, m_currentEndItem, m_currentNode, m_fitOk, m_lastNode, route(), and updateLeadingRatLine().
Referenced by FlipPosture(), SetLayer(), SetOrthoMode(), and ToggleVia().
Definition at line 115 of file pns_diff_pair_placer.cpp.
References PNS::ITEM::ANY_T, PNS::NODE::CheckColliding(), PNS::VIA::Diameter(), PNS::SIZES_SETTINGS::DiffPairGap(), PNS::SIZES_SETTINGS::DiffPairWidth(), PNS::NODE::GetClearance(), m_currentLayer, m_currentNode, m_currentTrace, m_placingVia, m_sizes, makeVia(), PNS::DIFF_PAIR::PLine(), PNS::VIA::Pos(), PNS::ITEM::RelevantShapeLayers(), PNS::RM_MarkObstacles, PNS::RM_Walkaround, PNS::VIA::SetDiameter(), PNS::ITEM::SetLayer(), PNS::VIA::SetPos(), PNS::ALGO_BASE::Settings(), PNS::VIA::Shape(), PNS::ITEM::SOLID_T, VECTOR2< T >::SquaredEuclideanNorm(), and viaGap().
Referenced by routeHead().
|
private |
Definition at line 101 of file pns_diff_pair_placer.cpp.
References PNS::NODE::CheckColliding(), m_currentNode, m_currentTrace, m_fitOk, PNS::DIFF_PAIR::NLine(), PNS::DIFF_PAIR::PLine(), and routeHead().
Referenced by route().
|
private |
route step, mark obstacles mode
Definition at line 351 of file pns_diff_pair_placer.cpp.
References PNS::ITEM_SET::Add(), PNS::NODE::CheckColliding(), m_currentNode, m_currentTrace, m_fitOk, m_shove, PNS::DIFF_PAIR::NLine(), PNS::DIFF_PAIR::PLine(), routeHead(), PNS::SHOVE::SH_INCOMPLETE, PNS::SHOVE::SH_OK, and tryWalkDp().
Referenced by route().
|
private |
route step, shove mode
Definition at line 322 of file pns_diff_pair_placer.cpp.
References m_currentNode, m_currentTrace, m_fitOk, routeHead(), and tryWalkDp().
Referenced by route().
|
private |
Re-route the current track to point aP.
Returns true, when routing has completed successfully (i.e. the trace end has reached point aP), and false if the trace was stuck somewhere on the way. May call routeStep() repetitively due to mouse smoothing.
aP | is the ending point of current route. |
Definition at line 333 of file pns_diff_pair_placer.cpp.
References rhMarkObstacles(), rhShoveOnly(), rhWalkOnly(), PNS::RM_MarkObstacles, PNS::RM_Shove, PNS::RM_Walkaround, and PNS::ALGO_BASE::Settings().
Referenced by Move().
|
private |
Definition at line 659 of file pns_diff_pair_placer.cpp.
References DIRECTION_45::ANG_HALF_FULL, DIRECTION_45::ANG_STRAIGHT, PNS::DIFF_PAIR::AppendVias(), PNS::DP_GATEWAYS::BuildForCursor(), PNS::DP_GATEWAYS::BuildFromPrimitivePair(), PNS::DIFF_PAIR::CN(), PNS::DIFF_PAIR::CP(), SHAPE_LINE_CHAIN::CPoint(), PNS::SIZES_SETTINGS::DiffPairGap(), PNS::SIZES_SETTINGS::DiffPairWidth(), PNS::DP_GATEWAYS::FilterByOrientation(), FindDpPrimitivePair(), PNS::DP_GATEWAYS::FitGateways(), gap(), SEG::LineProject(), m_currentEndItem, m_currentLayer, m_currentNode, m_currentTrace, m_currentTraceOk, m_fitOk, m_netN, m_netP, m_placingVia, m_prevPair, m_sizes, m_snapOnTarget, m_start, m_startDiagonal, makeVia(), propagateDpHeadForces(), PNS::DIFF_PAIR::RemoveVias(), PNS::DP_GATEWAYS::SetFitVias(), PNS::DIFF_PAIR::SetGap(), PNS::ITEM::SetLayer(), PNS::DIFF_PAIR::SetNets(), PNS::DIFF_PAIR::SetWidth(), PNS::SIZES_SETTINGS::ViaDiameter(), and viaGap().
Referenced by rhMarkObstacles(), rhShoveOnly(), and rhWalkOnly().
|
inlineinherited |
Return current router settings.
Definition at line 54 of file pns_algo_base.h.
References PNS::ALGO_BASE::m_router.
Referenced by attemptWalk(), PNS::MEANDER_PLACER_BASE::Clearance(), CommitPlacement(), PNS::DP_MEANDER_PLACER::CommitPlacement(), PNS::LINE_PLACER::CommitPlacement(), PNS::MEANDER_PLACER::CommitPlacement(), PNS::COMPONENT_DRAGGER::FixRoute(), PNS::DRAGGER::FixRoute(), PNS::MULTI_DRAGGER::FixRoute(), initPlacement(), PNS::LINE_PLACER::initPlacement(), PNS::LINE_PLACER::makeVia(), PNS::MULTI_DRAGGER::multidragShove(), PNS::SHOVE::onCollidingSolid(), PNS::SHOVE::reconstructHeads(), PNS::SHOVE::removeHeads(), PNS::LINE_PLACER::rhWalkBase(), PNS::SHOVE::Run(), PNS::SHOVE::runOptimizer(), PNS::SHOVE::shoveIteration(), Start(), PNS::DP_MEANDER_PLACER::Start(), PNS::LINE_PLACER::Start(), PNS::MEANDER_PLACER::Start(), PNS::MEANDER_SKEW_PLACER::Start(), PNS::DRAGGER::Start(), PNS::MULTI_DRAGGER::Start(), PNS::DRAGGER::tryWalkaround(), and PNS::MULTI_DRAGGER::tryWalkaround().
|
inlineinherited |
Assign a debug decorator allowing this algo to draw extra graphics for visual debugging.
Definition at line 73 of file pns_algo_base.h.
References PNS::ALGO_BASE::m_debugDecorator.
Referenced by PNS::SHOVE::onCollidingSolid(), PNS::LINE_PLACER::rhWalkBase(), PNS::SHOVE::SHOVE(), PNS::DRAGGER::tryWalkaround(), and PNS::MULTI_DRAGGER::tryWalkaround().
|
private |
Set preferred direction of the very first track segment to be laid.
Used by posture switching mechanism.
|
overridevirtual |
Set the current routing layer.
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 420 of file pns_diff_pair_placer.cpp.
References initPlacement(), m_chainedPlacement, m_currentEnd, m_currentLayer, m_idle, m_prevPair, m_start, Move(), and PNS::ITEM::VIA_T.
|
inlineinherited |
Definition at line 65 of file pns_algo_base.h.
References PNS::ALGO_BASE::m_logger.
Referenced by PNS::LINE_PLACER::rhWalkBase(), PNS::DRAGGER::tryWalkaround(), and PNS::MULTI_DRAGGER::tryWalkaround().
|
overridevirtual |
Function SetOrthoMode()
Forces the router to place a straight 90/45 degree trace (with the end as near to the cursor as possible) instead of a standard 135 degree two-segment bend.
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 81 of file pns_diff_pair_placer.cpp.
References m_currentEnd, m_idle, m_orthoMode, and Move().
|
inherited |
Return the logger object, allowing to dump geometry to a file.
Definition at line 28 of file pns_algo_base.cpp.
References PNS::ALGO_BASE::m_router, and PNS::ROUTER::Settings().
Referenced by attemptWalk(), PNS::LINE_PLACER::buildInitialLine(), PNS::LINE_PLACER::CommitPlacement(), PNS::MULTI_DRAGGER::Drag(), PNS::DRAGGER::dragMarkObstacles(), PNS::DRAGGER::dragShove(), PNS::DRAGGER::dragWalkaround(), PNS::COMPONENT_DRAGGER::FixRoute(), PNS::MULTI_DRAGGER::FixRoute(), FixRoute(), PNS::LINE_PLACER::FixRoute(), PNS::LINE_PLACER::Move(), PNS::SHOVE::onCollidingSolid(), PNS::DRAGGER::optimizeAndUpdateDraggedLine(), propagateDpHeadForces(), PNS::DRAGGER::propagateViaForces(), PNS::SHOVE::pushOrShoveVia(), PNS::LINE_PLACER::rhMarkObstacles(), PNS::LINE_PLACER::rhShoveOnly(), PNS::LINE_PLACER::rhWalkBase(), PNS::LINE_PLACER::rhWalkOnly(), route(), PNS::LINE_PLACER::routeHead(), PNS::LINE_PLACER::routeStep(), PNS::SHOVE::runOptimizer(), PNS::SHOVE::shoveMainLoop(), PNS::WALKAROUND::singleStep(), PNS::LINE_PLACER::Start(), PNS::DRAGGER::Start(), PNS::MULTI_DRAGGER::Start(), PNS::DRAGGER::tryWalkaround(), PNS::MULTI_DRAGGER::tryWalkaround(), PNS::LINE_PLACER::UnfixRoute(), and PNS::WALKAROUND::WALKAROUND().
|
private |
Set the board to route.
Definition at line 65 of file pns_diff_pair_placer.cpp.
References m_world.
Referenced by initPlacement(), and Start().
Start routing a single track at point aP, taking item aStartItem as anchor (unless NULL).
Implements PNS::PLACEMENT_ALGO.
Definition at line 606 of file pns_diff_pair_placer.cpp.
References FindDpPrimitivePair(), initPlacement(), m_chainedPlacement, m_currentEnd, m_currentNode, m_currentStart, m_currentTrace, m_currentTraceOk, m_netN, m_netP, m_placingVia, m_start, m_world, PNS::ITEM::Net(), PNS::DP_PRIMITIVE_PAIR::PrimN(), PNS::DP_PRIMITIVE_PAIR::PrimP(), PNS::ALGO_BASE::Router(), PNS::ROUTER::SetFailureReason(), PNS::DIFF_PAIR::SetNets(), and setWorld().
|
overridevirtual |
Enable/disable a via at the end of currently routed trace.
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 90 of file pns_diff_pair_placer.cpp.
References m_currentEnd, m_idle, m_placingVia, and Move().
|
overridevirtual |
Return the complete routed line, as a single-member ITEM_SET.
Implements PNS::PLACEMENT_ALGO.
Definition at line 391 of file pns_diff_pair_placer.cpp.
References PNS::ITEM_SET::Add(), m_currentTrace, PNS::DIFF_PAIR::NLine(), and PNS::DIFF_PAIR::PLine().
route step, walk around mode
Definition at line 277 of file pns_diff_pair_placer.cpp.
References attemptWalk(), PNS::NODE::Branch(), PNS::DIFF_PAIR::CoupledLength(), m_currentNode, PNS::OPTIMIZER::Optimize(), PNS::DIFF_PAIR::SetShape(), and PNS::DIFF_PAIR::Skew().
Referenced by rhShoveOnly(), and rhWalkOnly().
|
inlinevirtualinherited |
Reimplemented in PNS::LINE_PLACER.
Definition at line 81 of file pns_placement_algo.h.
|
private |
Draw the "leading" ratsnest line, which connects the end of currently routed track and the nearest yet unrouted item.
If the routing for current net is complete, draws nothing.
Definition at line 879 of file pns_diff_pair_placer.cpp.
References PNS::ROUTER_IFACE::DisplayRatline(), PNS::ROUTER::GetInterface(), PNS::TOPOLOGY::LeadingRatLine(), m_currentTrace, m_lastNode, m_netN, m_netP, PNS::ALGO_BASE::m_router, PNS::DIFF_PAIR::NLine(), and PNS::DIFF_PAIR::PLine().
Referenced by Move().
|
overridevirtual |
Perform on-the-fly update of the width, via diameter & drill size from a settings class.
Used to dynamically change these parameters as the track is routed.
Reimplemented from PNS::PLACEMENT_ALGO.
Definition at line 764 of file pns_diff_pair_placer.cpp.
References PNS::SIZES_SETTINGS::DiffPairGap(), PNS::SIZES_SETTINGS::DiffPairWidth(), PNS::DIFF_PAIR::EndsWithVias(), m_currentTrace, m_idle, m_sizes, PNS::DIFF_PAIR::SetGap(), PNS::DIFF_PAIR::SetViaDiameter(), PNS::DIFF_PAIR::SetViaDrill(), PNS::DIFF_PAIR::SetWidth(), PNS::SIZES_SETTINGS::ViaDiameter(), and PNS::SIZES_SETTINGS::ViaDrill().
|
private |
Definition at line 593 of file pns_diff_pair_placer.cpp.
References PNS::SIZES_SETTINGS::DiffPairViaGap(), PNS::SIZES_SETTINGS::GetDiffPairHoleToHole(), m_sizes, PNS::SIZES_SETTINGS::ViaDiameter(), and PNS::SIZES_SETTINGS::ViaDrill().
Referenced by propagateDpHeadForces(), and routeHead().
|
inherited |
Definition at line 40 of file pns_algo_base.cpp.
References PNS::ALGO_BASE::m_router, and PNS::ROUTER::VisibleViewArea().
Referenced by PNS::SHOVE::runOptimizer().
|
private |
Definition at line 225 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), SetLayer(), and Start().
|
private |
Definition at line 273 of file pns_diff_pair_placer.h.
Referenced by CurrentEnd(), FlipPosture(), Move(), SetLayer(), SetOrthoMode(), Start(), and ToggleVia().
|
private |
Definition at line 277 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), initPlacement(), Move(), and routeHead().
|
private |
Definition at line 267 of file pns_diff_pair_placer.h.
Referenced by CurrentLayer(), DIFF_PAIR_PLACER(), propagateDpHeadForces(), routeHead(), and SetLayer().
|
private |
Postprocessed world state (including marked collisions & removed loops)
Definition at line 248 of file pns_diff_pair_placer.h.
Referenced by CommitPlacement(), CurrentNode(), DIFF_PAIR_PLACER(), initPlacement(), Move(), propagateDpHeadForces(), rhMarkObstacles(), rhShoveOnly(), rhWalkOnly(), routeHead(), Start(), and tryWalkDp().
|
private |
Definition at line 273 of file pns_diff_pair_placer.h.
Referenced by CurrentStart(), and Start().
|
private |
Definition at line 274 of file pns_diff_pair_placer.h.
Referenced by FixRoute(), HasPlacedAnything(), propagateDpHeadForces(), rhMarkObstacles(), rhShoveOnly(), rhWalkOnly(), routeHead(), Start(), Traces(), updateLeadingRatLine(), and UpdateSizes().
|
private |
Definition at line 275 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), routeHead(), and Start().
|
private |
Definition at line 265 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
protectedinherited |
Definition at line 86 of file pns_algo_base.h.
Referenced by PNS::ALGO_BASE::Dbg(), and PNS::ALGO_BASE::SetDebugDecorator().
|
private |
Definition at line 228 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), Move(), rhMarkObstacles(), rhShoveOnly(), rhWalkOnly(), and routeHead().
|
private |
Definition at line 279 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), FlipPosture(), initPlacement(), SetLayer(), SetOrthoMode(), ToggleVia(), and UpdateSizes().
|
private |
Definition at line 226 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), and initPlacement().
|
private |
pointer to world to search colliding items
Definition at line 236 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
private |
Definition at line 251 of file pns_diff_pair_placer.h.
Referenced by CommitPlacement(), CurrentNode(), DIFF_PAIR_PLACER(), FixRoute(), initPlacement(), Move(), and updateLeadingRatLine().
|
protectedinherited |
Definition at line 88 of file pns_algo_base.h.
Referenced by PNS::ALGO_BASE::Logger(), and PNS::ALGO_BASE::SetLogger().
|
private |
Definition at line 230 of file pns_diff_pair_placer.h.
Referenced by CurrentNets(), DIFF_PAIR_PLACER(), GetModifiedNets(), routeHead(), Start(), and updateLeadingRatLine().
|
private |
Definition at line 230 of file pns_diff_pair_placer.h.
Referenced by CurrentNets(), DIFF_PAIR_PLACER(), GetModifiedNets(), routeHead(), Start(), and updateLeadingRatLine().
|
private |
Definition at line 270 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), initPlacement(), and SetOrthoMode().
|
private |
The shove engine.
Definition at line 242 of file pns_diff_pair_placer.h.
|
private |
current via diameter
Definition at line 256 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), IsPlacingVia(), propagateDpHeadForces(), routeHead(), Start(), and ToggleVia().
|
private |
current algorithm iteration
Definition at line 233 of file pns_diff_pair_placer.h.
Referenced by FixRoute(), routeHead(), and SetLayer().
|
protectedinherited |
Definition at line 87 of file pns_algo_base.h.
Referenced by PNS::MEANDER_PLACER::doMove(), PNS::LINE_PLACER::FixRoute(), PNS::MEANDER_PLACER_BASE::lineLength(), PNS::DP_MEANDER_PLACER::Move(), PNS::MEANDER_SKEW_PLACER::Move(), PNS::ALGO_BASE::Router(), PNS::ALGO_BASE::Settings(), updateLeadingRatLine(), PNS::LINE_PLACER::updateLeadingRatLine(), and PNS::ALGO_BASE::VisibleViewArea().
|
private |
Current world state.
Definition at line 245 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), initPlacement(), and rhShoveOnly().
|
private |
Are we placing a via?
Definition at line 253 of file pns_diff_pair_placer.h.
Referenced by gap(), makeVia(), propagateDpHeadForces(), routeHead(), UpdateSizes(), and viaGap().
|
private |
Definition at line 271 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FixRoute(), and routeHead().
|
private |
Definition at line 232 of file pns_diff_pair_placer.h.
Referenced by routeHead(), SetLayer(), and Start().
|
private |
Definition at line 227 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER(), FlipPosture(), initPlacement(), and routeHead().
|
private |
Definition at line 269 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
private |
Definition at line 223 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
private |
current via drill
Definition at line 259 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
private |
current track width
Definition at line 262 of file pns_diff_pair_placer.h.
Referenced by DIFF_PAIR_PLACER().
|
private |
current routing start point (end of tail, beginning of head)
Definition at line 239 of file pns_diff_pair_placer.h.
Referenced by AbortPlacement(), DIFF_PAIR_PLACER(), setWorld(), and Start().