mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-23 18:56:23 +00:00
Don't fail on product without placement
This commit is contained in:
@@ -8,7 +8,12 @@ taxonomy::ptr mapping::map_impl(const IfcSchema::IfcProduct* inst) {
|
|||||||
// @todo decide on this, what happens in the product mapping?
|
// @todo decide on this, what happens in the product mapping?
|
||||||
// currently things like openings, layers and materials are processed in the converter
|
// currently things like openings, layers and materials are processed in the converter
|
||||||
auto c = taxonomy::make<taxonomy::collection>();
|
auto c = taxonomy::make<taxonomy::collection>();
|
||||||
c->matrix = taxonomy::cast<taxonomy::matrix4>(map(inst->ObjectPlacement()));
|
if (inst->ObjectPlacement()) {
|
||||||
|
c->matrix = taxonomy::cast<taxonomy::matrix4>(map(inst->ObjectPlacement()));
|
||||||
|
} else {
|
||||||
|
// @todo Otherwise we get crashes in the serializer, but maybe fix them there..?
|
||||||
|
c->matrix = taxonomy::make<taxonomy::matrix4>();
|
||||||
|
}
|
||||||
return c;
|
return c;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
Reference in New Issue
Block a user