mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-20 04:04:00 +00:00
Points and wires
This commit is contained in:
@@ -28,13 +28,14 @@ bool IfcGeom::CgalKernel::convert(const IfcSchema::IfcExtrudedAreaSolid*, cgal_s
|
||||
}
|
||||
|
||||
bool IfcGeom::CgalKernel::convert(const IfcSchema::IfcCartesianPoint* l, cgal_point_t& point) {
|
||||
// IN_CACHE(IfcCartesianPoint,l,gp_Pnt,point)
|
||||
// std::vector<double> xyz = l->Coordinates();
|
||||
// point = gp_Pnt(
|
||||
// xyz.size() ? (xyz[0]*getValue(GV_LENGTH_UNIT)) : 0.0f,
|
||||
// xyz.size() > 1 ? (xyz[1]*getValue(GV_LENGTH_UNIT)) : 0.0f,
|
||||
// xyz.size() > 2 ? (xyz[2]*getValue(GV_LENGTH_UNIT)) : 0.0f
|
||||
// );
|
||||
// CACHE(IfcCartesianPoint,l,point)
|
||||
return true;
|
||||
std::vector<double> xyz = l->Coordinates();
|
||||
// for (const double &coordinate: xyz) std::cout << coordinate << " ";
|
||||
// std::cout << std::endl;
|
||||
if (xyz.size() == 3) {
|
||||
point = new Kernel::Point_3(xyz[0], xyz[1], xyz[2]);
|
||||
return true;
|
||||
} else {
|
||||
point = new Kernel::Point_3();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user