KiCad PCB EDA Suite
Loading...
Searching...
No Matches
step_pcb_model.cpp File Reference
#include <algorithm>
#include <cmath>
#include <sstream>
#include <string>
#include <utility>
#include <wx/filename.h>
#include <wx/filefn.h>
#include <wx/stdpaths.h>
#include <wx/wfstream.h>
#include <wx/zipstrm.h>
#include <wx/stdstream.h>
#include <decompress.hpp>
#include <footprint.h>
#include <pad.h>
#include <pcb_track.h>
#include <kiplatform/io.h>
#include <string_utils.h>
#include <build_version.h>
#include <geometry/shape_segment.h>
#include <geometry/shape_circle.h>
#include <board_stackup_manager/board_stackup.h>
#include <board_stackup_manager/stackup_predefined_prms.h>
#include "step_pcb_model.h"
#include "streamwrapper.h"
#include <IGESCAFControl_Reader.hxx>
#include <IGESCAFControl_Writer.hxx>
#include <IGESControl_Controller.hxx>
#include <IGESData_GlobalSection.hxx>
#include <IGESData_IGESModel.hxx>
#include <Interface_Static.hxx>
#include <Quantity_Color.hxx>
#include <STEPCAFControl_Reader.hxx>
#include <STEPCAFControl_Writer.hxx>
#include <APIHeaderSection_MakeHeader.hxx>
#include <Standard_Failure.hxx>
#include <Standard_Version.hxx>
#include <TCollection_ExtendedString.hxx>
#include <TDocStd_Document.hxx>
#include <TDataStd_Name.hxx>
#include <TDataStd_TreeNode.hxx>
#include <TDF_LabelSequence.hxx>
#include <TDF_ChildIterator.hxx>
#include <TopExp_Explorer.hxx>
#include <XCAFApp_Application.hxx>
#include <XCAFDoc.hxx>
#include <XCAFDoc_DocumentTool.hxx>
#include <XCAFDoc_ColorTool.hxx>
#include <XCAFDoc_ShapeTool.hxx>
#include <BRep_Tool.hxx>
#include <BRepMesh_IncrementalMesh.hxx>
#include <BRepBuilderAPI.hxx>
#include <BRepBuilderAPI_Transform.hxx>
#include <BRepBuilderAPI_GTransform.hxx>
#include <BRepBuilderAPI_MakeEdge.hxx>
#include <BRepBuilderAPI_MakeWire.hxx>
#include <BRepBuilderAPI_MakeFace.hxx>
#include <BRepPrimAPI_MakePrism.hxx>
#include <BRepPrimAPI_MakeCylinder.hxx>
#include <BRepTools.hxx>
#include <BRepLib_MakeWire.hxx>
#include <BRepAlgoAPI_Check.hxx>
#include <BRepAlgoAPI_Cut.hxx>
#include <BRepAlgoAPI_Fuse.hxx>
#include <ShapeUpgrade_UnifySameDomain.hxx>
#include <BRepBndLib.hxx>
#include <Bnd_BoundSortBox.hxx>
#include <Geom_Curve.hxx>
#include <Geom_TrimmedCurve.hxx>
#include <gp_Ax2.hxx>
#include <gp_Dir.hxx>
#include <gp_Pnt.hxx>
#include <GC_MakeArcOfCircle.hxx>
#include <GC_MakeCircle.hxx>
#include <RWGltf_CafWriter.hxx>
#include <macros.h>

Go to the source code of this file.

Enumerations

enum  MODEL3D_FORMAT_TYPE {
  FMT_NONE , FMT_STEP , FMT_STEPZ , FMT_IGES ,
  FMT_EMN , FMT_IDF , FMT_WRL , FMT_WRZ
}
 

Functions

MODEL3D_FORMAT_TYPE fileType (const char *aFileName)
 
static VECTOR2D CircleCenterFrom3Points (const VECTOR2D &p1, const VECTOR2D &p2, const VECTOR2D &p3)
 
static SHAPE_LINE_CHAIN approximateLineChainWithArcs (const SHAPE_LINE_CHAIN &aSrc)
 
static wxString formatBBox (const BOX2I &aBBox)
 

Variables

static constexpr double USER_PREC = 1e-4
 
static constexpr double USER_ANGLE_PREC = 1e-6
 
static constexpr double BOARD_OFFSET = 0.05
 

Enumeration Type Documentation

◆ MODEL3D_FORMAT_TYPE

Enumerator
FMT_NONE 
FMT_STEP 
FMT_STEPZ 
FMT_IGES 
FMT_EMN 
FMT_IDF 
FMT_WRL 
FMT_WRZ 

Definition at line 119 of file step_pcb_model.cpp.

Function Documentation

◆ approximateLineChainWithArcs()

◆ CircleCenterFrom3Points()

static VECTOR2D CircleCenterFrom3Points ( const VECTOR2D p1,
const VECTOR2D p2,
const VECTOR2D p3 
)
static

Definition at line 196 of file step_pcb_model.cpp.

References VECTOR2< T >::x, and VECTOR2< T >::y.

Referenced by approximateLineChainWithArcs(), and CalcArcCenter().

◆ fileType()

◆ formatBBox()

static wxString formatBBox ( const BOX2I aBBox)
static

Variable Documentation

◆ BOARD_OFFSET

constexpr double BOARD_OFFSET = 0.05
staticconstexpr

Definition at line 116 of file step_pcb_model.cpp.

Referenced by STEP_PCB_MODEL::getModelLocation().

◆ USER_ANGLE_PREC

constexpr double USER_ANGLE_PREC = 1e-6
staticconstexpr

Definition at line 113 of file step_pcb_model.cpp.

Referenced by STEP_PCB_MODEL::STEP_PCB_MODEL().

◆ USER_PREC

constexpr double USER_PREC = 1e-4
staticconstexpr

Definition at line 112 of file step_pcb_model.cpp.