Utilities useful for splines in general Reference for B-Spline implementation: https://mat.fsv.cvut.cz/gcg/sbornik/prochazkova.pdf. More...
Functions | |
| std::vector< Point > | circularControlPoints (const libMesh::Point &start_point, const libMesh::Point &end_point, const libMesh::RealVectorValue ¶llel_direction, const unsigned int num_cps) |
| Creates control points for the special case of parallel lines using an interpolating circle. More... | |
| std::vector< Point > | bSplineControlPoints (const libMesh::Point &start_point, const libMesh::Point &end_point, const libMesh::RealVectorValue &start_direction, const libMesh::RealVectorValue &end_direction, const unsigned int cps_per_half, const libMesh::Real sharpness) |
| Creates control points for an open uniform BSpline. More... | |
| std::vector< Point > | controlPointsAlongLine (const libMesh::Point &start_point, const libMesh::Point &end_point, const libMesh::RealVectorValue &direction_vector, const libMesh::Real sharpness, const unsigned int num_cps, const bool reverse_order=false) |
| Creates control points along an extrapolated line up to a certain intercept. More... | |
| libMesh::Point | makeControlPoint (const libMesh::Point &start_point, const libMesh::Point &end_point, const libMesh::RealVectorValue &direction_vector, const libMesh::Real sharpness) |
| Creates a control point. More... | |
| std::pair< Point, Point > | closestPoints (const libMesh::Point &point_1, const libMesh::Point &point_2, const libMesh::RealVectorValue &direction_1, const libMesh::RealVectorValue &direction_2) |
| Determines the two points defining the shortest line segment between two lines in space. More... | |
Utilities useful for splines in general Reference for B-Spline implementation: https://mat.fsv.cvut.cz/gcg/sbornik/prochazkova.pdf.
| std::vector< Point > SplineUtils::bSplineControlPoints | ( | const libMesh::Point & | start_point, |
| const libMesh::Point & | end_point, | ||
| const libMesh::RealVectorValue & | start_direction, | ||
| const libMesh::RealVectorValue & | end_direction, | ||
| const unsigned int | cps_per_half, | ||
| const libMesh::Real | sharpness | ||
| ) |
Creates control points for an open uniform BSpline.
| start_point | start point for spline |
| end_point | end point for spline |
| start_direction | incoming direction (derivative) |
| end_direction | outgoing direction (derivative) |
| cps_per_half | number of control points per half of the spline – will be along extrapolated line from the point and its direction |
| sharpness | number in [0,1] that determines the sharpness of the curve |
Definition at line 67 of file SplineUtils.C.
Referenced by Moose::BSpline::createControlPoints(), and BSplineCurveGenerator::generate().
| std::vector< Point > SplineUtils::circularControlPoints | ( | const libMesh::Point & | start_point, |
| const libMesh::Point & | end_point, | ||
| const libMesh::RealVectorValue & | parallel_direction, | ||
| const unsigned int | num_cps | ||
| ) |
Creates control points for the special case of parallel lines using an interpolating circle.
| start_point | start point for spline |
| end_point | end point for spline |
| parallel_direction | direction of both curves to be connected. must be the same for both |
| num_cps | total number of control points to be created |
Definition at line 19 of file SplineUtils.C.
Referenced by bSplineControlPoints().
| std::pair< Point, Point > SplineUtils::closestPoints | ( | const libMesh::Point & | point_1, |
| const libMesh::Point & | point_2, | ||
| const libMesh::RealVectorValue & | direction_1, | ||
| const libMesh::RealVectorValue & | direction_2 | ||
| ) |
Determines the two points defining the shortest line segment between two lines in space.
If the lines intersect, the two points returned will be identical.
| point_1 | starting point of the first line |
| point_2 | starting point of the second line |
| direction_1 | direction of the first line |
| direction_2 | direction of the second line |
Definition at line 184 of file SplineUtils.C.
Referenced by bSplineControlPoints().
| std::vector< Point > SplineUtils::controlPointsAlongLine | ( | const libMesh::Point & | start_point, |
| const libMesh::Point & | end_point, | ||
| const libMesh::RealVectorValue & | direction_vector, | ||
| const libMesh::Real | sharpness, | ||
| const unsigned int | num_cps, | ||
| const bool | reverse_order = false |
||
| ) |
Creates control points along an extrapolated line up to a certain intercept.
| start_point | start point for the line |
| end_point | end point of the line |
| direction_vector | direction of the line |
| sharpness | number in [0,1] that determines the sharpness of the future curve. In this context, it will determine how close to the end point the control points are placed. |
| reverse_order | boolean to return the vector of control points in the reverse order |
Definition at line 122 of file SplineUtils.C.
Referenced by bSplineControlPoints().
| libMesh::Point SplineUtils::makeControlPoint | ( | const libMesh::Point & | start_point, |
| const libMesh::Point & | end_point, | ||
| const libMesh::RealVectorValue & | direction_vector, | ||
| const libMesh::Real | sharpness | ||
| ) |
Creates a control point.
Subroutine of controlPointsAlongLine
| start_point | start point for the line |
| end_point | end point of the line |
| direction_vector | direction of the line |
| sharpness | number in [0,1] that determines the sharpness of the future curve. In this context, it will determine how close to the end point the control point is placed. |
Definition at line 154 of file SplineUtils.C.
Referenced by controlPointsAlongLine().
1.8.14