mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-11 10:06:47 +00:00
Fixes problem evaluating gradient and segmented reference curves with start locations offset from start of base curve.
This commit is contained in:
@@ -101,9 +101,7 @@ struct gradient_fn_evaluator : public fn_evaluator {
|
||||
double end() const override { return fn_->end(); }
|
||||
|
||||
Eigen::Matrix4d evaluate(double u) const override {
|
||||
// u is distance from start of vertical.
|
||||
// add vertical->start() to u to get distance from start of horizontal
|
||||
auto xy = horizontal_evaluator_.evaluate(u + start_);
|
||||
auto xy = horizontal_evaluator_.evaluate(u);
|
||||
auto uz = vertical_evaluator_.evaluate(u);
|
||||
|
||||
// curvature is stored in row 3 - capture it and remove it from the xy and uz matrices
|
||||
@@ -148,9 +146,7 @@ struct cant_fn_evaluator : public fn_evaluator {
|
||||
double end() const override { return fn_->end(); }
|
||||
|
||||
Eigen::Matrix4d evaluate(double u) const override {
|
||||
// u is distance from start of cant curve
|
||||
// add cant->start() to u to get the distance from start of gradient curve
|
||||
auto g = gradient_evaluator_.evaluate(u + start_);
|
||||
auto g = gradient_evaluator_.evaluate(u);
|
||||
auto c = cant_evaluator_.evaluate(u);
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user