- Ifc: get rid of erroneous error messages.

pull/17/head
Alexander Gessler 2013-01-30 13:01:16 +01:00
parent 35128a7251
commit 2359a83132
1 changed files with 10 additions and 8 deletions

View File

@ -2686,10 +2686,6 @@ bool ProcessGeometricItem(const IfcRepresentationItem& geo, std::vector<unsigned
return false; return false;
} }
if (meshtmp->IsEmpty()) {
return false;
}
// Do we just collect openings for a parent element (i.e. a wall)? // Do we just collect openings for a parent element (i.e. a wall)?
// In such a case, we generate the polygonal mesh as usual, // In such a case, we generate the polygonal mesh as usual,
// but attach it to a TempOpening instance which will later be applied // but attach it to a TempOpening instance which will later be applied
@ -2698,13 +2694,19 @@ bool ProcessGeometricItem(const IfcRepresentationItem& geo, std::vector<unsigned
// Note: swep area solids are added in ProcessExtrudedAreaSolid(), // Note: swep area solids are added in ProcessExtrudedAreaSolid(),
// which returns an empty mesh. // which returns an empty mesh.
if(conv.collect_openings) { if(conv.collect_openings) {
conv.collect_openings->push_back(TempOpening(geo.ToPtr<IfcSolidModel>(), if (!meshtmp->IsEmpty()) {
IfcVector3(0,0,0), conv.collect_openings->push_back(TempOpening(geo.ToPtr<IfcSolidModel>(),
meshtmp, IfcVector3(0,0,0),
boost::shared_ptr<TempMesh>(NULL))); meshtmp,
boost::shared_ptr<TempMesh>(NULL)));
}
return true; return true;
} }
if (meshtmp->IsEmpty()) {
return false;
}
meshtmp->RemoveAdjacentDuplicates(); meshtmp->RemoveAdjacentDuplicates();
meshtmp->RemoveDegenerates(); meshtmp->RemoveDegenerates();