mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Small fixes to transformations
This commit is contained in:
@@ -34,17 +34,13 @@ namespace IfcGeom {
|
||||
operator const cgal_placement_t& () { return trsf_; }
|
||||
|
||||
virtual double Value(int i, int j) const {
|
||||
// TODO: Check
|
||||
// std::cout << "Getting CgalPlacement with i = " << i << " and j = " << j << std::endl;
|
||||
return CGAL::to_double(trsf_.cartesian(i-1, j-1));
|
||||
return CGAL::to_double(trsf_.cartesian(i-1, j-1));
|
||||
}
|
||||
virtual void Multiply(const ConversionResultPlacement* other) {
|
||||
// TODO: Check
|
||||
trsf_ = ((CgalPlacement *)other)->trsf_ * trsf_;
|
||||
trsf_ = trsf_ * ((CgalPlacement *)other)->trsf_;
|
||||
}
|
||||
virtual void PreMultiply(const ConversionResultPlacement* other) {
|
||||
// TODO: Check
|
||||
trsf_ = trsf_ * ((CgalPlacement *)other)->trsf_;
|
||||
trsf_ = ((CgalPlacement *)other)->trsf_ * trsf_;
|
||||
}
|
||||
virtual ConversionResultPlacement* clone() const {
|
||||
return new CgalPlacement(trsf_);
|
||||
|
||||
@@ -236,10 +236,9 @@ bool IfcGeom::CgalKernel::convert(const IfcSchema::IfcCartesianTransformationOpe
|
||||
return true;
|
||||
}
|
||||
|
||||
bool IfcGeom::CgalKernel::convert(const IfcSchema::IfcCartesianTransformationOperator2DnonUniform* l, cgal_placement_t& gtrsf) {
|
||||
bool IfcGeom::CgalKernel::convert(const IfcSchema::IfcCartesianTransformationOperator2DnonUniform* l, cgal_placement_t& trsf) {
|
||||
// IN_CACHE(IfcCartesianTransformationOperator2DnonUniform,l,cgal_placement_t,gtrsf)
|
||||
|
||||
cgal_placement_t trsf;
|
||||
cgal_point_t origin;
|
||||
cgal_direction_t axis1 (1.,0.,0.);
|
||||
cgal_direction_t axis2 (0.,1.,0.);
|
||||
|
||||
Reference in New Issue
Block a user