|
|
|
The result of a NurbsCurveEvaluator.
More...
#include "nurbsCurveResult.h"
List of all members.
Classes |
| class | AdaptiveSample |
Public Member Functions |
| | NurbsCurveResult (const NurbsBasisVector &basis, const LVecBase4 vecs[], const NurbsVertex *verts, int num_vertices) |
| | The constructor automatically builds up the result as the product of the indicated set of basis matrices and the indicated table of control vertex positions.
|
| void | adaptive_sample (PN_stdfloat tolerance) |
| | Determines the set of subdivisions necessary to approximate the curve with a set of linear segments, no point of which is farther than tolerance units from the actual curve.
|
| PN_stdfloat | eval_extended_point (PN_stdfloat t, int d) |
| | Evaluates the curve in n-dimensional space according to the extended vertices associated with the curve in the indicated dimension.
|
| bool | eval_extended_points (PN_stdfloat t, int d, PN_stdfloat result[], int num_values) |
| | Simultaneously performs eval_extended_point on a contiguous sequence of dimensions.
|
| bool | eval_point (PN_stdfloat t, LVecBase3 &point) |
| | Computes the point on the curve corresponding to the indicated value in parametric time.
|
| PN_stdfloat | eval_segment_extended_point (int segment, PN_stdfloat t, int d) const |
| | Evaluates the curve in n-dimensional space according to the extended vertices associated with the curve in the indicated dimension.
|
| void | eval_segment_extended_points (int segment, PN_stdfloat t, int d, PN_stdfloat result[], int num_values) const |
| | Simultaneously performs eval_extended_point on a contiguous sequence of dimensions.
|
| void | eval_segment_point (int segment, PN_stdfloat t, LVecBase3 &point) const |
| | Evaluates the point on the curve corresponding to the indicated value in parametric time within the indicated curve segment.
|
| void | eval_segment_tangent (int segment, PN_stdfloat t, LVecBase3 &tangent) const |
| | As eval_segment_point, but computes the tangent to the curve at the indicated point.
|
| bool | eval_tangent (PN_stdfloat t, LVecBase3 &tangent) |
| | Computes the tangent to the curve at the indicated point in parametric time.
|
| PN_stdfloat | get_end_t () const |
| | Returns the last legal value of t on the curve.
|
| int | get_num_samples () const |
| | Returns the number of sample points generated by the previous call to adaptive_sample().
|
| int | get_num_segments () const |
| | Returns the number of piecewise continuous segments within the curve.
|
| const LPoint3 & | get_sample_point (int n) const |
| | Returns the point on the curve of the nth sample point generated by the previous call to adaptive_sample().
|
| PN_stdfloat | get_sample_t (int n) const |
| | Returns the t value of the nth sample point generated by the previous call to adaptive_sample().
|
| PN_stdfloat | get_segment_t (int segment, PN_stdfloat t) const |
| | Accepts a t value in the range [0, 1], and assumed to be relative to the indicated segment (as in eval_segment_point()), and returns the corresponding t value in the entire curve (as in eval_point()).
|
| PN_stdfloat | get_start_t () const |
| | Returns the first legal value of t on the curve.
|
|
| MAKE_SEQ (get_sample_ts, get_num_samples, get_sample_t) |
|
| MAKE_SEQ (get_sample_points, get_num_samples, get_sample_points) |
Detailed Description
The result of a NurbsCurveEvaluator.
This object represents a curve in a particular coordinate space. It can return the point and/or tangent to the curve at any point.
This is not related to NurbsCurve, CubicCurveseg or any of the ParametricCurve-derived objects in this module. It is a completely parallel implementation of NURBS curves, and will probably eventually replace the whole ParametricCurve class hierarchy.
Definition at line 38 of file nurbsCurveResult.h.
Constructor & Destructor Documentation
Member Function Documentation
Evaluates the point on the curve corresponding to the indicated value in parametric time within the indicated curve segment.
t should be in the range [0, 1].
The curve is internally represented as a number of connected (or possibly unconnected) piecewise continuous segments. The exact number of segments for a particular curve depends on the knot vector, and is returned by get_num_segments(). Normally, eval_point() is used to evaluate a point along the continuous curve, but when you care more about local continuity, you can use eval_segment_point() to evaluate the points along each segment.
Definition at line 81 of file nurbsCurveResult.cxx.
Referenced by adaptive_sample(), and eval_point().
As eval_segment_point, but computes the tangent to the curve at the indicated point.
The tangent vector will not necessarily be normalized, and could be zero, particularly at the endpoints.
Definition at line 101 of file nurbsCurveResult.cxx.
Referenced by eval_tangent().
The documentation for this class was generated from the following files:
| | |