mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-11 22:31:55 +00:00
Further work on trying to get orientation properly mapped
This commit is contained in:
@@ -52,15 +52,14 @@ taxonomy::ptr mapping::map_impl(const IfcSchema::IfcCompositeCurve* inst) {
|
||||
else if (segment->as<IfcSchema::IfcCompositeCurveSegment>()) {
|
||||
auto crv = map(segment->as<IfcSchema::IfcCompositeCurveSegment>()->ParentCurve());
|
||||
if (crv) {
|
||||
if (!segment->as<IfcSchema::IfcCompositeCurveSegment>()->SameSense()) {
|
||||
crv->reverse();
|
||||
}
|
||||
if (crv->kind() == taxonomy::EDGE) {
|
||||
auto ecrv = taxonomy::cast<taxonomy::edge>(crv);
|
||||
ecrv->curve_sense.reset(segment->as<IfcSchema::IfcCompositeCurveSegment>()->SameSense());
|
||||
loop->children.push_back(ecrv);
|
||||
}
|
||||
else if (crv->kind() == taxonomy::LOOP) {
|
||||
if (!segment->as<IfcSchema::IfcCompositeCurveSegment>()->SameSense()) {
|
||||
crv->reverse();
|
||||
}
|
||||
for (auto& s : taxonomy::cast<taxonomy::loop>(crv)->children) {
|
||||
loop->children.push_back(s);
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ taxonomy::ptr mapping::map_impl(const IfcSchema::IfcTrimmedCurve* inst) {
|
||||
bool has_flts[2] = {false,false};
|
||||
bool has_pnts[2] = {false,false};
|
||||
|
||||
tc->orientation = inst->SenseAgreement();
|
||||
tc->curve_sense = inst->SenseAgreement();
|
||||
|
||||
for (auto it = trims1->begin(); it != trims1->end(); it ++) {
|
||||
auto i = *it;
|
||||
|
||||
Reference in New Issue
Block a user