TraceMaker
C++ API of the engine
Loading...
Searching...
No Matches
tmk::place::Part Struct Reference

#include <place/problem.hpp>

Public Member Functions

bool may_flip () const
int side_in (int state) const
double angle_of (int state) const

Public Attributes

int fp = -1
 footprint index in the board
std::string ref
std::string lib_id
bool movable = false
bool copper_only = false
 ExtractOptions::copper_only: only its copper and holes are tested against other parts.
std::string fixed_reason
 why a part is fixed (locked, mounting hole, ...)
int side = 0
 0 front, 1 back: the footprint's side in the input
bool flippable = false
 May move to the other side (states 4–7): movable, surface mount only (no holes), the board has two copper sides, flipping was asked for, and the writer can mirror the footprint (doc 04 §3 C/E, D48).
std::string flip_reason
 why a movable part may not flip (empty when it may, or when flipping is off)
Point pos0
 original origin
double angle0 = 0
 original absolute orientation (degrees); see kStates for state angles
std::array< PartGeom, kStates > geom
 per state (states 4–7 only filled for flippable parts)
std::vector< int > pins
 indices into Problem::pins
Coord area = 0
 courtyard box area incl. clearance (nm², saturating), for spreading
std::uint64_t shape_key = 0
 equal keys = interchangeable footprints (swap moves)

Detailed Description

Definition at line 64 of file problem.hpp.

Member Function Documentation

◆ angle_of()

double tmk::place::Part::angle_of ( int state) const
inline

Definition at line 80 of file problem.hpp.

◆ may_flip()

bool tmk::place::Part::may_flip ( ) const
inline

Definition at line 78 of file problem.hpp.

◆ side_in()

int tmk::place::Part::side_in ( int state) const
inline

Definition at line 79 of file problem.hpp.

Member Data Documentation

◆ angle0

double tmk::place::Part::angle0 = 0

original absolute orientation (degrees); see kStates for state angles

Definition at line 76 of file problem.hpp.

◆ area

Coord tmk::place::Part::area = 0

courtyard box area incl. clearance (nm², saturating), for spreading

Definition at line 82 of file problem.hpp.

◆ copper_only

bool tmk::place::Part::copper_only = false

ExtractOptions::copper_only: only its copper and holes are tested against other parts.

Definition at line 68 of file problem.hpp.

◆ fixed_reason

std::string tmk::place::Part::fixed_reason

why a part is fixed (locked, mounting hole, ...)

Definition at line 69 of file problem.hpp.

◆ flip_reason

std::string tmk::place::Part::flip_reason

why a movable part may not flip (empty when it may, or when flipping is off)

Definition at line 74 of file problem.hpp.

◆ flippable

bool tmk::place::Part::flippable = false

May move to the other side (states 4–7): movable, surface mount only (no holes), the board has two copper sides, flipping was asked for, and the writer can mirror the footprint (doc 04 §3 C/E, D48).

Definition at line 73 of file problem.hpp.

◆ fp

int tmk::place::Part::fp = -1

footprint index in the board

Definition at line 65 of file problem.hpp.

◆ geom

std::array<PartGeom, kStates> tmk::place::Part::geom

per state (states 4–7 only filled for flippable parts)

Definition at line 77 of file problem.hpp.

◆ lib_id

std::string tmk::place::Part::lib_id

Definition at line 66 of file problem.hpp.

◆ movable

bool tmk::place::Part::movable = false

Definition at line 67 of file problem.hpp.

◆ pins

std::vector<int> tmk::place::Part::pins

indices into Problem::pins

Definition at line 81 of file problem.hpp.

◆ pos0

Point tmk::place::Part::pos0

original origin

Definition at line 75 of file problem.hpp.

◆ ref

std::string tmk::place::Part::ref

Definition at line 66 of file problem.hpp.

◆ shape_key

std::uint64_t tmk::place::Part::shape_key = 0

equal keys = interchangeable footprints (swap moves)

Definition at line 83 of file problem.hpp.

◆ side

int tmk::place::Part::side = 0

0 front, 1 back: the footprint's side in the input

Definition at line 70 of file problem.hpp.


The documentation for this struct was generated from the following file: