Open CASCADE Technology  7.7.0.dev
Static Public Member Functions

RWStl Class Reference

This class provides methods to read and write triangulation from / to the STL files. More...

#include <RWStl.hxx>

Static Public Member Functions

static Standard_Boolean WriteBinary (const Handle< Poly_Triangulation > &theMesh, const OSD_Path &thePath, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Write triangulation to binary STL file. binary format of an STL file. Returns false if the cannot be opened;. More...
 
static Standard_Boolean WriteAscii (const Handle< Poly_Triangulation > &theMesh, const OSD_Path &thePath, const Message_ProgressRange &theProgress=Message_ProgressRange())
 write the meshing in a file following the Ascii format of an STL file. Returns false if the cannot be opened; More...
 
static Handle< Poly_TriangulationReadFile (const OSD_Path &theFile, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read specified STL file and returns its content as triangulation. In case of error, returns Null handle. More...
 
static Handle< Poly_TriangulationReadFile (const Standard_CString theFile, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read specified STL file and returns its content as triangulation. In case of error, returns Null handle. More...
 
static Handle< Poly_TriangulationReadFile (const Standard_CString theFile, const Standard_Real theMergeAngle, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read specified STL file and returns its content as triangulation. More...
 
static void ReadFile (const Standard_CString theFile, const Standard_Real theMergeAngle, NCollection_Sequence< Handle< Poly_Triangulation >> &theTriangList, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read specified STL file and fills triangulation list for multi-domain case. More...
 
static Handle< Poly_TriangulationReadBinary (const OSD_Path &thePath, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read triangulation from a binary STL file In case of error, returns Null handle. More...
 
static Handle< Poly_TriangulationReadAscii (const OSD_Path &thePath, const Message_ProgressRange &theProgress=Message_ProgressRange())
 Read triangulation from an Ascii STL file In case of error, returns Null handle. More...
 

Detailed Description

This class provides methods to read and write triangulation from / to the STL files.

Member Function Documentation

◆ ReadAscii()

static Handle< Poly_Triangulation > RWStl::ReadAscii ( const OSD_Path thePath,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Read triangulation from an Ascii STL file In case of error, returns Null handle.

◆ ReadBinary()

static Handle< Poly_Triangulation > RWStl::ReadBinary ( const OSD_Path thePath,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Read triangulation from a binary STL file In case of error, returns Null handle.

◆ ReadFile() [1/4]

static Handle< Poly_Triangulation > RWStl::ReadFile ( const OSD_Path theFile,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Read specified STL file and returns its content as triangulation. In case of error, returns Null handle.

◆ ReadFile() [2/4]

static Handle< Poly_Triangulation > RWStl::ReadFile ( const Standard_CString  theFile,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
inlinestatic

Read specified STL file and returns its content as triangulation. In case of error, returns Null handle.

◆ ReadFile() [3/4]

static Handle< Poly_Triangulation > RWStl::ReadFile ( const Standard_CString  theFile,
const Standard_Real  theMergeAngle,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Read specified STL file and returns its content as triangulation.

Parameters
[in]theFilefile path to read
[in]theMergeAnglemaximum angle in radians between triangles to merge equal nodes; M_PI/2 means ignore angle
[in]theProgressprogress indicator
Returns
result triangulation or NULL in case of error

◆ ReadFile() [4/4]

static void RWStl::ReadFile ( const Standard_CString  theFile,
const Standard_Real  theMergeAngle,
NCollection_Sequence< Handle< Poly_Triangulation >> &  theTriangList,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Read specified STL file and fills triangulation list for multi-domain case.

Parameters
[in]theFilefile path to read
[in]theMergeAnglemaximum angle in radians between triangles to merge equal nodes; M_PI/2 means ignore angle
[out]theTriangListtriangulation list for multi-domain case
[in]theProgressprogress indicator

◆ WriteAscii()

static Standard_Boolean RWStl::WriteAscii ( const Handle< Poly_Triangulation > &  theMesh,
const OSD_Path thePath,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

write the meshing in a file following the Ascii format of an STL file. Returns false if the cannot be opened;

◆ WriteBinary()

static Standard_Boolean RWStl::WriteBinary ( const Handle< Poly_Triangulation > &  theMesh,
const OSD_Path thePath,
const Message_ProgressRange theProgress = Message_ProgressRange() 
)
static

Write triangulation to binary STL file. binary format of an STL file. Returns false if the cannot be opened;.


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