Description
Hi team
I am currently wrestling with a mock up of little tool to write IFC files using IfcTesselatedFaceSet and IfcFacetedBrep.
Specifically, I am trying to implement some sort of vertex de-duplication functionality, as the input meshes I want to convert, may not be completely free of duplicate vertices.
Now when handling a creation of an IfcFacetedBrep, I can get rid of the duplicate vertices relatively easily through a mere comparison of the individual vertex coordinates, and simply only create new IfcCartesianPoint instance for unique vertices, and get reference to an existing IfcCartesianPoint instance for all of the duplicate ones.
However, when handling creation of an IfcTesselatedFaceSet, coordinates are written directly into the IfcCartesianPointList3D, which is a mere list of point coordinates, rather than set of separate IfcCartesianPoint class instances I could reference to instead of creating one anew.
I wonder, whether there is any means I may be overlooking, that would help me reduce the duplicate vertices in the case of IfcTesselatedFaceSet as well, or it is by principle simply not possible?
Many thanks,
M.