Major update: taxonomy shared pointers, collection type safety, work towards hashing

This commit is contained in:
Thomas Krijnen
2023-07-27 16:42:06 +08:00
parent 98a73f1646
commit 65a5646bf0
122 changed files with 1669 additions and 1203 deletions
+6 -6
View File
@@ -21,17 +21,17 @@
#define mapping POSTFIX_SCHEMA(mapping)
using namespace ifcopenshell::geometry;
taxonomy::item* mapping::map_impl(const IfcSchema::IfcCurveBoundedPlane* inst) {
taxonomy::plane pl = as<taxonomy::plane>(map(inst->BasisSurface()));
auto f = new taxonomy::face;
f->children.push_back(map(inst->OuterBoundary()));
taxonomy::ptr mapping::map_impl(const IfcSchema::IfcCurveBoundedPlane* inst) {
taxonomy::plane::ptr pl = taxonomy::cast<taxonomy::plane>(map(inst->BasisSurface()));
auto f = taxonomy::make<taxonomy::face>();
f->children.push_back(taxonomy::cast<taxonomy::loop>(map(inst->OuterBoundary())));
IfcSchema::IfcCurve::list::ptr boundaries = inst->InnerBoundaries();
for (IfcSchema::IfcCurve::list::it it = boundaries->begin(); it != boundaries->end(); ++it) {
f->children.push_back(map(*it));
f->children.push_back(taxonomy::cast<taxonomy::loop>(map(*it)));
}
f->matrix = pl.matrix;
f->matrix = pl->matrix;
return f;
}