29#include "../../3d_math.h"
45 const float radius = aCircle->
GetRadius() * 2.0f;
49 const float f = ( sqrtf( 2.0f ) / 2.0f ) * radius * texture_factor;
53 SFVEC3F( center.x - f, center.y, aZtop ),
54 SFVEC3F( center.x, center.y - f, aZtop ) );
57 SFVEC3F( center.x + f, center.y, aZtop ),
58 SFVEC3F( center.x, center.y + f, aZtop ) );
61 SFVEC3F( center.x + f, center.y, aZbot ),
62 SFVEC3F( center.x, center.y - f, aZbot ) );
65 SFVEC3F( center.x - f, center.y, aZbot ),
66 SFVEC3F( center.x, center.y + f, aZbot ) );
72 float aZtop,
float aZbot )
85 float aOuterRadius,
unsigned int aNr_sides_per_circle,
86 std::vector< SFVEC2F >& aInnerContourResult,
87 std::vector< SFVEC2F >& aOuterContourResult,
90 aInnerContourResult.clear();
91 aInnerContourResult.reserve( aNr_sides_per_circle + 2 );
93 aOuterContourResult.clear();
94 aOuterContourResult.reserve( aNr_sides_per_circle + 2 );
96 const int delta = 3600 / aNr_sides_per_circle;
98 for(
int ii = 0; ii < 3600; ii +=
delta )
100 float angle = (float)( aInvertOrder ? ( 3600 - ii ) : ii )
101 * 2.0f * glm::pi<float>() / 3600.0f;
104 aInnerContourResult.emplace_back( aCenter.x + rotatedDir.x * aInnerRadius,
105 aCenter.y + rotatedDir.y * aInnerRadius );
107 aOuterContourResult.emplace_back( aCenter.x + rotatedDir.x * aOuterRadius,
108 aCenter.y + rotatedDir.y * aOuterRadius );
111 aInnerContourResult.push_back( aInnerContourResult[0] );
112 aOuterContourResult.push_back( aOuterContourResult[0] );
114 wxASSERT( aInnerContourResult.size() == aOuterContourResult.size() );
119 float aZtop,
float aZbot )
125 std::vector< SFVEC2F > innerContour;
126 std::vector< SFVEC2F > outerContour;
129 innerContour, outerContour,
false );
132 for(
unsigned int i = 0; i < ( innerContour.size() - 1 ); ++i )
134 const SFVEC2F& vi0 = innerContour[i + 0];
135 const SFVEC2F& vi1 = innerContour[i + 1];
136 const SFVEC2F& vo0 = outerContour[i + 0];
137 const SFVEC2F& vo1 = outerContour[i + 1];
140 SFVEC3F( vi0.x, vi0.y, aZtop ),
141 SFVEC3F( vo0.x, vo0.y, aZtop ),
142 SFVEC3F( vo1.x, vo1.y, aZtop ) );
145 SFVEC3F( vo1.x, vo1.y, aZbot ),
146 SFVEC3F( vo0.x, vo0.y, aZbot ),
147 SFVEC3F( vi0.x, vi0.y, aZbot ) );
154 float aZtop,
float aZbot )
166 float aZtop,
float aZbot )
183 const float radius_of_the_square = sqrtf( aSeg->
GetRadiusSquared() * 2.0f );
184 const float radius_triangle_factor = ( radius_of_the_square - radius ) / radius;
186 const SFVEC2F factorS =
SFVEC2F( -rightDir.y * radius * radius_triangle_factor,
187 rightDir.x * radius * radius_triangle_factor );
189 const SFVEC2F factorE =
SFVEC2F( -leftDir.y * radius * radius_triangle_factor,
190 leftDir.x * radius * radius_triangle_factor );
194 SFVEC3F( rightEnd.x + texture_factor * factorS.x,
195 rightEnd.y + texture_factor * factorS.y,
197 SFVEC3F( leftStart.x + texture_factor * factorE.x,
198 leftStart.y + texture_factor * factorE.y,
200 SFVEC3F( start.x - texture_factorF * leftDir.x * radius * sqrtf( 2.0f ),
201 start.y - texture_factorF * leftDir.y * radius * sqrtf( 2.0f ),
205 SFVEC3F( leftEnd.x + texture_factor * factorE.x,
206 leftEnd.y + texture_factor * factorE.y, aZtop ),
207 SFVEC3F( rightStart.x + texture_factor * factorS.x,
208 rightStart.y + texture_factor * factorS.y, aZtop ),
209 SFVEC3F( end.x - texture_factorF * rightDir.x * radius * sqrtf( 2.0f ),
210 end.y - texture_factorF * rightDir.y * radius * sqrtf( 2.0f ),
215 SFVEC3F( leftStart.x + texture_factor * factorE.x,
216 leftStart.y + texture_factor * factorE.y,
218 SFVEC3F( rightEnd.x + texture_factor * factorS.x,
219 rightEnd.y + texture_factor * factorS.y,
221 SFVEC3F( start.x - texture_factorF * leftDir.x * radius * sqrtf( 2.0f ),
222 start.y - texture_factorF * leftDir.y * radius * sqrtf( 2.0f ),
226 SFVEC3F( rightStart.x + texture_factor * factorS.x,
227 rightStart.y + texture_factor * factorS.y, aZbot ),
228 SFVEC3F( leftEnd.x + texture_factor * factorE.x,
229 leftEnd.y + texture_factor * factorE.y, aZbot ),
230 SFVEC3F( end.x - texture_factorF * rightDir.x * radius * sqrtf( 2.0f ),
231 end.y - texture_factorF * rightDir.y * radius * sqrtf( 2.0f ),
236 SFVEC3F( rightEnd.x, rightEnd.y, aZtop ),
237 SFVEC3F( rightStart.x, rightStart.y, aZtop ),
238 SFVEC3F( leftEnd.x, leftEnd.y, aZtop ),
239 SFVEC3F( leftStart.x, leftStart.y, aZtop ) );
242 SFVEC3F( rightEnd.x, rightEnd.y, aZbot ),
243 SFVEC3F( leftStart.x, leftStart.y, aZbot ),
244 SFVEC3F( leftEnd.x, leftEnd.y, aZbot ),
245 SFVEC3F( rightStart.x, rightStart.y, aZbot ) );
251 float aZbot,
bool aInvertFaces,
256 if( aListHolesObject2d.size() > 0 )
262 for(
const OBJECT_2D* itemOnLayer : aListHolesObject2d )
264 const OBJECT_2D* object2d_A = itemOnLayer;
266 wxASSERT( ( object2d_A->
GetObjectType() == OBJECT_2D_TYPE::FILLED_CIRCLE )
267 || ( object2d_A->
GetObjectType() == OBJECT_2D_TYPE::ROUNDSEG ) );
271 case OBJECT_2D_TYPE::FILLED_CIRCLE:
273 layerTriangles, aZtop, aZbot );
276 case OBJECT_2D_TYPE::ROUNDSEG:
278 layerTriangles, aZtop, aZbot );
282 wxFAIL_MSG( wxT(
"RENDER_3D_OPENGL::generateHoles: Object type not implemented" ) );
293 aInvertFaces, aThroughHoles );
298 delete layerTriangles;
310 if( aContainer ==
nullptr )
315 if( listObject2d.size() == 0 )
318 float layer_z_bot = 0.0f;
319 float layer_z_top = 0.0f;
324 unsigned int nrTrianglesEstimation = listObject2d.size() * 8;
332 for(
const OBJECT_2D* itemOnLayer : listObject2d )
334 const OBJECT_2D* object2d_A = itemOnLayer;
338 case OBJECT_2D_TYPE::FILLED_CIRCLE:
340 layerTriangles, layer_z_top, layer_z_bot );
343 case OBJECT_2D_TYPE::POLYGON4PT:
345 layerTriangles, layer_z_top, layer_z_bot );
348 case OBJECT_2D_TYPE::RING:
350 layerTriangles, layer_z_top, layer_z_bot );
353 case OBJECT_2D_TYPE::TRIANGLE:
355 layerTriangles, layer_z_top, layer_z_bot );
358 case OBJECT_2D_TYPE::ROUNDSEG:
360 layerTriangles, layer_z_top, layer_z_bot );
364 wxFAIL_MSG( wxT(
"RENDER_3D_OPENGL: Object type is not implemented" ) );
382 float layer_z_bot = 0.0f;
383 float layer_z_top = 0.0f;
407 if( listBoardObject2d.size() > 0 )
411 const float layer_z_top = 1.0f;
412 const float layer_z_bot = 0.0f;
418 for(
const OBJECT_2D* itemOnLayer : listBoardObject2d )
420 const OBJECT_2D* object2d_A = itemOnLayer;
422 wxASSERT( object2d_A->
GetObjectType() == OBJECT_2D_TYPE::TRIANGLE );
440 layer_z_top, layer_z_top );
443 delete layerTriangles;
465 if( aStatusReporter )
466 aStatusReporter->
Report(
_(
"Load OpenGL: board" ) );
493 if( aStatusReporter )
494 aStatusReporter->
Report(
_(
"Load OpenGL: holes and vias" ) );
517 wxASSERT( innerMapHoles.size() == outerMapHoles.size() );
521 if( outerMapHoles.size() > 0 )
523 float layer_z_bot = 0.0f;
524 float layer_z_top = 0.0f;
526 for(
const auto& [ layer, poly ] : outerMapHoles )
531 layer_z_top, layer_z_bot,
false );
534 for(
const auto& [ layer, poly ] : innerMapHoles )
539 layer_z_top, layer_z_bot,
false );
547 if( aStatusReporter )
548 aStatusReporter->
Report(
_(
"Load OpenGL: layers" ) );
559 if( aStatusReporter )
562 aStatusReporter->
Report( wxString::Format(
_(
"Load OpenGL layer %s" ), msg ) );
572 if( map_poly.find( layer ) != map_poly.end() )
574 polyListSubtracted = *map_poly.at( layer );
592 if( layer ==
B_SilkS && map_poly.find(
B_Mask ) != map_poly.end() )
597 else if( layer ==
F_SilkS && map_poly.find(
F_Mask ) != map_poly.end() )
604 polyList = &polyListSubtracted;
611 if( oglList !=
nullptr )
620 if( frontPlatedPadAndGraphicPolys )
634 if( backPlatedPadAndGraphicPolys )
659 if( aStatusReporter )
660 aStatusReporter->
Report(
_(
"Loading 3D models..." ) );
664 if( aStatusReporter )
669 aStatusReporter->
Report( wxString::Format(
_(
"Reload time %.3f s" ), calculation_time ) );
693 if( aOutZtop < aOutZbot )
695 float tmpFloat = aOutZbot;
703 float aOuterRadius,
float aZtop,
float aZbot,
704 unsigned int aNr_sides_per_circle,
707 std::vector< SFVEC2F > innerContour;
708 std::vector< SFVEC2F > outerContour;
710 generateRing( aCenter, aInnerRadius, aOuterRadius, aNr_sides_per_circle, innerContour,
711 outerContour,
false );
713 for(
unsigned int i = 0; i < ( innerContour.size() - 1 ); ++i )
715 const SFVEC2F& vi0 = innerContour[i + 0];
716 const SFVEC2F& vi1 = innerContour[i + 1];
717 const SFVEC2F& vo0 = outerContour[i + 0];
718 const SFVEC2F& vo1 = outerContour[i + 1];
721 SFVEC3F( vi0.x, vi0.y, aZtop ),
722 SFVEC3F( vo0.x, vo0.y, aZtop ),
723 SFVEC3F( vo1.x, vo1.y, aZtop ) );
726 SFVEC3F( vo1.x, vo1.y, aZbot ),
727 SFVEC3F( vo0.x, vo0.y, aZbot ),
728 SFVEC3F( vi0.x, vi0.y, aZbot ) );
761 if(
via->GetViaType() == VIATYPE::THROUGH )
766 const float hole_inner_radius = holediameter / 2.0f;
772 via->LayerPair( &top_layer, &bottom_layer );
774 float ztop, zbot,
dummy;
779 wxASSERT( zbot < ztop );
782 hole_inner_radius + platingThickness3d,
783 ztop, zbot, nrSegments, layerTriangleVIA );
789 delete layerTriangleVIA;
808 if(
via->GetViaType() == VIATYPE::THROUGH )
811 via->GetDrill() / 2 + platingThickness,
823 for(
const PAD*
pad : footprint->Pads() )
825 if(
pad->GetAttribute() != PAD_ATTRIB::NPTH )
828 const bool hasHole = drillsize.
x && drillsize.
y;
833 pad->TransformHoleToPolygon( tht_outer_holes_poly, platingThickness,
853 if( holes2D.size() > 0 )
855 float layer_z_top, layer_z_bot,
dummy;
863 for(
const OBJECT_2D* itemOnLayer : holes2D )
865 const OBJECT_2D* object2d_A = itemOnLayer;
867 wxASSERT( object2d_A->
GetObjectType() == OBJECT_2D_TYPE::TRIANGLE );
883 layer_z_bot, layer_z_top,
887 layer_z_top, layer_z_top );
890 delete layerTriangles;
901 if( wxFrame* frame =
dynamic_cast<wxFrame*
>(
m_canvas->GetParent() ) )
904 (
int) EDA_3D_VIEWER_STATUSBAR::ACTIVITY );
935 wxString libraryName = footprint->GetFPID().GetLibNickname();
936 wxString footprintBasePath = wxEmptyString;
945 ->
FindRow( libraryName,
false );
948 footprintBasePath = fpRow->
GetFullURI(
true );
956 for(
const FP_3DMODEL& fp_model : footprint->Models() )
958 if( fp_model.m_Show && !fp_model.m_Filename.empty() )
960 if( aStatusReporter )
964 wxFileName fn( fp_model.m_Filename );
965 aStatusReporter->
Report( wxString::Format(
_(
"Loading %s..." ),
966 fn.GetFullName() ) );
MATERIAL_MODE
Render 3d model shape materials mode.
constexpr int ARC_HIGH_DEF
std::map< PCB_LAYER_ID, SHAPE_POLY_SET * > MAP_POLY
A type that stores polysets for each layer id.
std::map< PCB_LAYER_ID, BVH_CONTAINER_2D * > MAP_CONTAINER_2D_BASE
A type that stores a container of 2d objects for each layer id.
double BiuTo3dUnits() const noexcept
Board integer units To 3D units.
const SHAPE_POLY_SET * GetFrontPlatedPadAndGraphicPolys()
const MAP_CONTAINER_2D_BASE & GetLayerHoleMap() const noexcept
const SHAPE_POLY_SET & GetBoardPoly() const noexcept
Get the current polygon of the epoxy board.
const SHAPE_POLY_SET & GetNPTH_ODPolys() const noexcept
const BVH_CONTAINER_2D * GetOffboardPadsFront() const noexcept
const SHAPE_POLY_SET & GetViaTH_ODPolys() const noexcept
const MAP_POLY & GetPolyMap() const noexcept
Get map of polygon's layers.
const MAP_POLY & GetHoleOdPolysMap() const noexcept
std::bitset< LAYER_3D_END > GetVisibleLayers() const
bool m_IsPreviewer
true if we're in a 3D preview panel, false for the standard 3D viewer
int GetHolePlatingThickness() const noexcept
Get the hole plating thickness (NB: in BOARD UNITS!).
void InitSettings(REPORTER *aStatusReporter, REPORTER *aWarningReporter)
Function to be called by the render when it need to reload the settings for the board.
const BVH_CONTAINER_2D & GetViaAnnuli() const noexcept
float GetLayerBottomZPos(PCB_LAYER_ID aLayerId) const noexcept
Get the bottom z position.
const BVH_CONTAINER_2D * GetOffboardPadsBack() const noexcept
const BVH_CONTAINER_2D & GetTH_IDs() const noexcept
const BVH_CONTAINER_2D * GetPlatedPadsBack() const noexcept
const MAP_POLY & GetHoleIdPolysMap() const noexcept
float GetAverageViaHoleDiameter() const noexcept
unsigned int GetViaCount() const noexcept
const BOARD * GetBoard() const noexcept
const SFVEC3F & GetBoardCenter() const noexcept
The board center position in 3D units.
float GetLayerTopZPos(PCB_LAYER_ID aLayerId) const noexcept
Get the top z position.
const BVH_CONTAINER_2D & GetTH_ODs() const noexcept
const MAP_CONTAINER_2D_BASE & GetLayerMap() const noexcept
Get the map of containers that have the objects per layer.
EDA_3D_VIEWER_SETTINGS * m_Cfg
unsigned int GetHoleCount() const noexcept
const BVH_CONTAINER_2D * GetPlatedPadsFront() const noexcept
unsigned int GetCircleSegmentCount(float aDiameter3DU) const
const BVH_CONTAINER_2D & GetViaTH_ODs() const noexcept
const SHAPE_POLY_SET & GetViaAnnuliPolys() const noexcept
const SHAPE_POLY_SET * GetBackPlatedPadAndGraphicPolys()
bool Is3dLayerEnabled(PCB_LAYER_ID aLayer, const std::bitset< LAYER_3D_END > &aVisibilityFlags) const
Check if a layer is enabled.
S3D_CACHE * Get3dCacheManager() const noexcept
const SHAPE_POLY_SET & GetTH_ODPolys() const noexcept
Get through hole outside diameter 2D polygons.
A base class for any item which can be embedded within the BOARD container class, and therefore insta...
const FOOTPRINTS & Footprints() const
const TRACKS & Tracks() const
const wxString GetLayerName(PCB_LAYER_ID aLayer) const
Return the name of a aLayer.
PROJECT * GetProject() const
void SetBoardLookAtPos(const SFVEC3F &aBoardPos)
const LIST_OBJECT2D & GetList() const
const SFVEC2F & GetCenter() const
Hold a record identifying a library accessed by the appropriate footprint library #PLUGIN object in t...
const FP_LIB_TABLE_ROW * FindRow(const wxString &aNickName, bool aCheckIfEnabled=false)
Return an FP_LIB_TABLE_ROW if aNickName is found in this table or in any chained fall back table frag...
const wxString GetFullURI(bool aSubstituted=false) const
Return the full location specifying URI for the LIB, either in original UI form or in environment var...
static LSET PhysicalLayersMask()
Return a mask holding all layers which are physically realized.
static OBJECT_2D_STATS & Instance()
OBJECT_2D_TYPE GetObjectType() const
Store the OpenGL display lists to related with a layer.
void SetItIsTransparent(bool aSetTransparent)
Simple non-intersecting polygon with 4 points.
const SFVEC2F & GetV3() const
const SFVEC2F & GetV0() const
const SFVEC2F & GetV1() const
const SFVEC2F & GetV2() const
static FP_LIB_TABLE * PcbFootprintLibs(PROJECT *aProject)
Return the table of footprint libraries without Kiway.
CAMERA & m_camera
Flag if the canvas specific for this render was already initialized.
bool m_reloadRequested
The window size that this camera is working.
BOARD_ADAPTER & m_boardAdapter
OPENGL_RENDER_LIST * m_board
void reload(REPORTER *aStatusReporter, REPORTER *aWarningReporter)
OPENGL_RENDER_LIST * m_vias
OPENGL_RENDER_LIST * generateHoles(const LIST_OBJECT2D &aListHolesObject2d, const SHAPE_POLY_SET &aPoly, float aZtop, float aZbot, bool aInvertFaces, const BVH_CONTAINER_2D *aThroughHoles=nullptr)
void generateCylinder(const SFVEC2F &aCenter, float aInnerRadius, float aOuterRadius, float aZtop, float aZbot, unsigned int aNr_sides_per_circle, TRIANGLE_DISPLAY_LIST *aDstLayer)
OPENGL_RENDER_LIST * m_outerThroughHoleRings
OPENGL_RENDER_LIST * m_offboardPadsFront
void generateRing(const SFVEC2F &aCenter, float aInnerRadius, float aOuterRadius, unsigned int aNr_sides_per_circle, std::vector< SFVEC2F > &aInnerContourResult, std::vector< SFVEC2F > &aOuterContourResult, bool aInvertOrder)
SHAPE_POLY_SET m_antiBoardPolys
The negative polygon representation of the board outline.
void load3dModels(REPORTER *aStatusReporter)
Load footprint models from the cache and load it to openGL lists in the form of MODEL_3D objects.
void generateViasAndPads()
OPENGL_RENDER_LIST * generateLayerList(const BVH_CONTAINER_2D *aContainer, const SHAPE_POLY_SET *aPolyList, PCB_LAYER_ID aLayer, const BVH_CONTAINER_2D *aThroughHoles=nullptr)
OPENGL_RENDER_LIST * createBoard(const SHAPE_POLY_SET &aBoardPoly, const BVH_CONTAINER_2D *aThroughHoles=nullptr)
void Load3dModelsIfNeeded()
Load footprint models if they are not already loaded, i.e.
void addObjectTriangles(const RING_2D *aRing, TRIANGLE_DISPLAY_LIST *aDstLayer, float aZtop, float aZbot)
MAP_OGL_DISP_LISTS m_layers
MAP_OGL_DISP_LISTS m_innerLayerHoles
OPENGL_RENDER_LIST * m_boardWithHoles
MAP_OGL_DISP_LISTS m_outerLayerHoles
OPENGL_RENDER_LIST * m_offboardPadsBack
std::map< wxString, MODEL_3D * > m_3dModelMap
OPENGL_RENDER_LIST * generateEmptyLayerList(PCB_LAYER_ID aLayer)
LIST_TRIANGLES m_triangles
store pointers so can be deleted latter
OPENGL_RENDER_LIST * m_outerViaThroughHoles
OPENGL_RENDER_LIST * m_outerThroughHoles
OPENGL_RENDER_LIST * m_platedPadsFront
OPENGL_RENDER_LIST * m_antiBoard
void getLayerZPos(PCB_LAYER_ID aLayerID, float &aOutZtop, float &aOutZbot) const
OPENGL_RENDER_LIST * m_padHoles
void addTopAndBottomTriangles(TRIANGLE_DISPLAY_LIST *aDst, const SFVEC2F &v0, const SFVEC2F &v1, const SFVEC2F &v2, float top, float bot)
OPENGL_RENDER_LIST * m_platedPadsBack
A pure virtual class used to derive REPORTER objects from.
virtual REPORTER & Report(const wxString &aText, SEVERITY aSeverity=RPT_SEVERITY_UNDEFINED)=0
Report a string with a given severity.
float GetOuterRadius() const
float GetInnerRadius() const
const SFVEC2F & GetCenter() const
const SFVEC2F & GetLeftEnd() const
const SFVEC2F & GetRightEnd() const
const SFVEC2F & GetLeftStar() const
const SFVEC2F & GetLeftDir() const
const SFVEC2F & GetEnd() const
float GetRadiusSquared() const
const SFVEC2F & GetStart() const
const SFVEC2F & GetRightDir() const
const SFVEC2F & GetRightStar() const
S3DMODEL * GetModel(const wxString &aModelFileName, const wxString &aBasePath, const EMBEDDED_FILES *aEmbeddedFiles)
Attempt to load the scene data for a model and to translate it into an S3D_MODEL structure for displa...
void SetClosed(bool aClosed)
Mark the line chain as closed (i.e.
Represent a set of closed polygons.
void RemoveAllContours()
Remove all outlines & holes (clears) the polygon set.
void BooleanSubtract(const SHAPE_POLY_SET &b, POLYGON_MODE aFastMode)
Perform boolean polyset difference For aFastMode meaning, see function booleanOp.
void BooleanIntersection(const SHAPE_POLY_SET &b, POLYGON_MODE aFastMode)
Perform boolean polyset intersection For aFastMode meaning, see function booleanOp.
int Append(int x, int y, int aOutline=-1, int aHole=-1, bool aAllowDuplication=false)
Appends a vertex at the end of the given outline/hole (default: the last outline)
SHAPE_LINE_CHAIN & Outline(int aIndex)
Return the reference to aIndex-th outline in the set.
int NewOutline()
Creates a new empty polygon in the set and returns its index.
int OutlineCount() const
Return the number of outlines in the set.
SHAPE_POLY_SET CloneDropTriangulation() const
A wrapper for reporting to a specific text location in a statusbar.
const SFVEC2F & GetP2() const
const SFVEC2F & GetP3() const
const SFVEC2F & GetP1() const
Store arrays of triangles to be used to create display lists.
TRIANGLE_LIST * m_layer_bot_segment_ends
TRIANGLE_LIST * m_layer_top_segment_ends
TRIANGLE_LIST * m_layer_bot_triangles
TRIANGLE_LIST * m_layer_top_triangles
void AddToMiddleContourns(const SHAPE_LINE_CHAIN &outlinePath, float zBot, float zTop, double aBiuTo3Du, bool aInvertFaceDirection, const BVH_CONTAINER_2D *aThroughHoles=nullptr)
void AddTriangle(const SFVEC3F &aV1, const SFVEC3F &aV2, const SFVEC3F &aV3)
void AddQuad(const SFVEC3F &aV1, const SFVEC3F &aV2, const SFVEC3F &aV3, const SFVEC3F &aV4)
std::list< OBJECT_2D * > LIST_OBJECT2D
void TransformCircleToPolygon(SHAPE_LINE_CHAIN &aBuffer, const VECTOR2I &aCenter, int aRadius, int aError, ERROR_LOC aErrorLoc, int aMinSegCount=0)
Convert a circle to a polygon, using multiple straight lines.
Declaration of the eda_3d_viewer class.
PCB_LAYER_ID
A quick note on layer IDs:
int64_t GetRunningMicroSecs()
An alternate way to calculate an elapsed time (in microsecondes) to class PROF_COUNTER.
#define SIZE_OF_CIRCLE_TEXTURE
std::vector< FAB_LAYER_COLOR > dummy
bool opengl_copper_thickness
bool show_footprints_normal
MATERIAL_MODE material_mode
bool clip_silk_on_via_annuli
bool show_footprints_virtual
bool subtract_mask_from_silk
bool show_footprints_insert
bool DifferentiatePlatedCopper()
return true if platted copper aeras and non platted copper areas must be drawn using a different colo...
Store the a model based on meshes and materials.
void ConvertPolygonToTriangles(const SHAPE_POLY_SET &aPolyList, CONTAINER_2D_BASE &aDstContainer, float aBiuTo3dUnitsScale, const BOARD_ITEM &aBoardItem)
@ PCB_VIA_T
class PCB_VIA, a via (like a track segment on a copper layer)
VECTOR2< int32_t > VECTOR2I