KiCad PCB EDA Suite
Loading...
Searching...
No Matches
EASYPC_PCB::LAYER_MAPPER Class Reference

Layer mapping for one layer table, copper in stack order and other layers by their type. More...

#include <easypc_pcb_items.h>

Public Member Functions

 LAYER_MAPPER (const std::vector< const EASYPC::SOURCE_LAYER * > &aLayers)
 
std::vector< INPUT_LAYER_DESC > Describe () const
 
void ApplyUserMapping (const std::map< wxString, PCB_LAYER_ID > &aMapping)
 
PCB_LAYER_ID Map (const EASYPC::OBJECT *aLayer) const
 UNDEFINED_LAYER when the native layer has no KiCad layer.
 
LSET PadLayers (const EASYPC::OBJECT *aLayer, bool aComponentPad) const
 The copper aLayer (a layer or a set) covers, with the mask and paste layers whose type plots such pads.
 
const EASYPC::SOURCE_LAYER * Native (PCB_LAYER_ID aLayer) const
 
int32_t GrowByLayer (const EASYPC::SOURCE_LAYER *aLayer, int32_t aSize) const
 aSize grown on each side by aLayer's type oversize, fixed or a percentage of the size
 
int CopperCount () const
 

Private Attributes

std::vector< const EASYPC::SOURCE_LAYER * > m_layers
 
std::map< const EASYPC::SOURCE_LAYER *, PCB_LAYER_ID > m_map
 
int m_copperCount = 2
 

Detailed Description

Layer mapping for one layer table, copper in stack order and other layers by their type.

Definition at line 85 of file easypc_pcb_items.h.

Constructor & Destructor Documentation

◆ LAYER_MAPPER()

EASYPC_PCB::LAYER_MAPPER::LAYER_MAPPER ( const std::vector< const EASYPC::SOURCE_LAYER * > & aLayers)
explicit

Member Function Documentation

◆ ApplyUserMapping()

void EASYPC_PCB::LAYER_MAPPER::ApplyUserMapping ( const std::map< wxString, PCB_LAYER_ID > & aMapping)

Definition at line 552 of file easypc_pcb_items.cpp.

References m_map.

◆ CopperCount()

int EASYPC_PCB::LAYER_MAPPER::CopperCount ( ) const
inline

Definition at line 105 of file easypc_pcb_items.h.

References m_copperCount.

◆ Describe()

◆ GrowByLayer()

int32_t EASYPC_PCB::LAYER_MAPPER::GrowByLayer ( const EASYPC::SOURCE_LAYER * aLayer,
int32_t aSize ) const

aSize grown on each side by aLayer's type oversize, fixed or a percentage of the size

Definition at line 623 of file easypc_pcb_items.cpp.

References EASYPC::NONE, EASYPC::SOURCE_LAYER_TYPE::Oversize, EASYPC::SOURCE_LAYER_TYPE::OversizeType, EASYPC::PERCENT, and EASYPC::SOURCE_LAYER::Type.

◆ Map()

PCB_LAYER_ID EASYPC_PCB::LAYER_MAPPER::Map ( const EASYPC::OBJECT * aLayer) const

UNDEFINED_LAYER when the native layer has no KiCad layer.

Definition at line 562 of file easypc_pcb_items.cpp.

References m_map, and UNDEFINED_LAYER.

Referenced by EASYPC_PCB::AddShapeItem(), EASYPC_PCB::ApplyTextPosition(), Native(), and PadLayers().

◆ Native()

const SOURCE_LAYER * EASYPC_PCB::LAYER_MAPPER::Native ( PCB_LAYER_ID aLayer) const

Definition at line 611 of file easypc_pcb_items.cpp.

References m_layers, and Map().

◆ PadLayers()

Member Data Documentation

◆ m_copperCount

int EASYPC_PCB::LAYER_MAPPER::m_copperCount = 2
private

Definition at line 110 of file easypc_pcb_items.h.

Referenced by CopperCount(), and LAYER_MAPPER().

◆ m_layers

std::vector<const EASYPC::SOURCE_LAYER*> EASYPC_PCB::LAYER_MAPPER::m_layers
private

Definition at line 108 of file easypc_pcb_items.h.

Referenced by Describe(), LAYER_MAPPER(), Native(), and PadLayers().

◆ m_map

std::map<const EASYPC::SOURCE_LAYER*, PCB_LAYER_ID> EASYPC_PCB::LAYER_MAPPER::m_map
private

Definition at line 109 of file easypc_pcb_items.h.

Referenced by ApplyUserMapping(), Describe(), LAYER_MAPPER(), and Map().


The documentation for this class was generated from the following files: