20#ifndef VIA_CROSS_SECTION_GEOMETRY_H
21#define VIA_CROSS_SECTION_GEOMETRY_H
Manage layers needed to make a physical board.
Base material class that can be used to derive other material implementations.
double LayerCentre(int aOrdinal) const
Grid height of the centre of a copper layer, by ordinal.
std::vector< PIECE > m_bores
const std::vector< PIECE > & Bores() const
double GridHeight() const
CLIP
What is clipped out of a body.
@ UNDER_MASK
bores and cuts
void build(const STATE &aState)
VIA_CROSS_SECTION_GEOMETRY(const STATE &aState)
std::vector< PIECE > m_cuts
static double GridHeightFor(int aInnerLayers)
Grid height for a board with the given number of inner copper layers.
const BODY & Body(MATERIAL aMaterial) const
MATERIAL
The materials, in the order they are painted.
std::vector< BODY > m_bodies
const std::vector< PIECE > & Cuts() const
std::vector< double > m_layerCentres
static int SetLayersFromStackup(STATE &aState, const BOARD_STACKUP &aStackup, int aCopperLayerCount)
Fill the layer depths and thicknesses from a stackup, or leave them empty when it does not match the ...
static constexpr double GRID_W
const std::vector< BODY > & Bodies() const
std::vector< PIECE > m_Pieces
std::vector< POINT > m_Points
bool m_Rect
A rectangle holds its top left and bottom right corners, a polygon its outline.
A cut at the mouth of the hole.
std::optional< PAD_DRILL_POST_MACHINING_MODE > m_Mode
std::optional< bool > m_CoverBack
std::vector< double > m_LayerThicknesses
std::optional< bool > m_Capped
std::optional< bool > m_PlugFront
std::optional< bool > m_PlugBack
std::optional< bool > m_CoverFront
POST_MACHINING m_PostMachiningBack
double m_BackdrillFrontWidthRatio
std::optional< bool > m_TentFront
std::vector< bool > m_RingLayers
Which spanned copper layers keep an annular ring. Empty means all of them.
double m_BackdrillBackWidthRatio
std::vector< double > m_LayerDepths
Depth of each copper layer centre and its thickness, as fractions of the board thickness,...
int m_TopLayer
Copper layers the via spans, as ordinals where 0 is the front layer and the inner count plus one is t...
std::optional< bool > m_Filled
std::optional< int > m_BackdrillFrontLayers
Copper layers removed from that side by the backdrill, 0 for no backdrill, and the backdrill diameter...
std::optional< int > m_BackdrillBackLayers
std::optional< bool > m_TentBack
POST_MACHINING m_PostMachiningFront
double m_PadRatio
Pad diameter over hole diameter.
std::optional< int > m_BottomLayer
VIA_CROSS_SECTION_GEOMETRY::STATE STATE
VIA_CROSS_SECTION_GEOMETRY::BODY BODY