Navigation

Main Page
Download
Support
Installation
Tutorial
Examples
Reference Manual
   Version 1.0.6dev
      Class Index
      File List
   Version 1.0.6
   Version 1.0.5new_solver
   Version 1.0.5dev
   Version 1.0.5b
   Version 1.0.4dev
   Version 1.0.4
Publications


Hosted by Get Ion Beam Simulator at SourceForge.net. Fast, secure and Free Open Source software downloads

Stereolithography CAD file class. More...

#include <stlfile.hpp>

Public Member Functions

 STLFile (const std::string &filename, double vertex_matching_eps=1.0e-9, double signed_volume_eps=1.0e-15)
 Constructor for STL data from file. More...
 
 STLFile (const std::vector< Vec3D > &vertex, const std::vector< VTriangle > &triangle)
 Constructor for $STLFile from triangle and vertex data. More...
 
 ~STLFile ()
 Destructor. More...
 
void save (const std::string &filename, bool ascii=true) const
 Write to file. More...
 
bool inside (const Vec3D &x)
 Return if point x is inside solid. More...
 
void get_bbox (Vec3D &min, Vec3D &max) const
 Return bounding box in vectors min and max. More...
 
void debug_print (std::ostream &os) const
 Print debugging information to os. More...
 

Detailed Description

Stereolithography CAD file class.

Constructor & Destructor Documentation

◆ STLFile() [1/2]

STLFile::STLFile ( const std::string &  filename,
double  vertex_matching_eps = 1.0e-9,
double  signed_volume_eps = 1.0e-15 
)

Constructor for STL data from file.

Reads either binary or ascii STL-file from filename. Triangle vertices are connected if closer that vertex_matching_eps together (absolute distance in meters). During inside() evaluation a tetrahedron volume less than signed_volume_eps is judged to be in the limits of numerical accuracy.

◆ STLFile() [2/2]

STLFile::STLFile ( const std::vector< Vec3D > &  vertex,
const std::vector< VTriangle > &  triangle 
)

Constructor for $STLFile from triangle and vertex data.

◆ ~STLFile()

STLFile::~STLFile ( )

Destructor.

Member Function Documentation

◆ debug_print()

void STLFile::debug_print ( std::ostream &  os) const

Print debugging information to os.

◆ get_bbox()

void STLFile::get_bbox ( Vec3D min,
Vec3D max 
) const
inline

Return bounding box in vectors min and max.

◆ inside()

bool STLFile::inside ( const Vec3D x)
inline

Return if point x is inside solid.

◆ save()

void STLFile::save ( const std::string &  filename,
bool  ascii = true 
) const

Write to file.


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


Reference manual for Ion Beam Simulator 1.0.6dev
Generated by Doxygen 1.9.1 on Thu Sep 11 2025 09:37:24.