0030024: Data Exchange - STEP, IGES export support of BRep shapes based on tessellated geometry

Support of reading and writing tessellated geometry is added for the following STEP entities:
- triangulated face
- complex triangulated face
- tessellated shell
- tessellated solid
- tessellated shape representation

Models without BRep geometry (mesh formats like STL, OBJ and so on) are supported for writing to STEP.

New parameters are added to enable/disable tessellated geometry reading and writing:
- read.step.tessellated (On/Off/OnNoBRep) (On by default)
- write.step.tessellated (On/Off/OnNoBRep) (OnNoBRep by default)

OnNoBRep - tessellation is read/written only for entities for which there is no BRep representation.

Faces with poly triangulation are written in STEP as triangulated face entities with one coordinates list per face.
Only one poly triangulation per face (returned by BRep_Tool::Triangulation) is written to STEP.
This commit is contained in:
snn
2022-04-04 18:08:34 +03:00
committed by afokin
parent e9c43fee29
commit cec41bb93d
128 changed files with 9920 additions and 403 deletions

View File

@@ -248,6 +248,22 @@ STEPControl_Controller::STEPControl_Controller ()
Interface_Static::Init("step", "read.step.codepage", '&', "eval CP850"); // Resource_FormatType_CP850
Interface_Static::SetCVal("read.step.codepage", "UTF8");
// Tessellated geometry reading: Off by default
Interface_Static::Init("step", "read.step.tessellated", 'e', "");
Interface_Static::Init("step", "read.step.tessellated", '&', "enum 0");
Interface_Static::Init("step", "read.step.tessellated", '&', "eval Off"); // 0
Interface_Static::Init("step", "read.step.tessellated", '&', "eval On"); // 1
Interface_Static::Init("step", "read.step.tessellated", '&', "eval OnNoBRep"); // 2
Interface_Static::SetCVal("read.step.tessellated", "On");
// Tessellated geometry writing: Off by default
Interface_Static::Init("step", "write.step.tessellated", 'e', "");
Interface_Static::Init("step", "write.step.tessellated", '&', "enum 0");
Interface_Static::Init("step", "write.step.tessellated", '&', "eval Off"); // 0
Interface_Static::Init("step", "write.step.tessellated", '&', "eval On"); // 1
Interface_Static::Init("step", "write.step.tessellated", '&', "eval OnNoBRep"); // 2
Interface_Static::SetCVal("write.step.tessellated", "OnNoBRep");
Standard_STATIC_ASSERT((int)Resource_FormatType_CP850 - (int)Resource_FormatType_CP1250 == 18); // "Error: Invalid Codepage Enumeration"
init = Standard_True;