NurbsSurfaceResult

Inheritance:

Methods of NurbsSurfaceResult:

Methods of ReferenceCount:

evalExtendedPoint
float NurbsSurfaceResult::eval_extended_point(float u, float v, int d);

Description: Evaluates the surface in n-dimensional space according to the extended vertices associated with the surface in the indicated dimension.

evalExtendedPoints
bool NurbsSurfaceResult::eval_extended_points(float u, float v, int d, void *result[](unsigned int size), int num_values);

Description: Simultaneously performs eval_extended_point on a contiguous sequence of dimensions. The dimensions evaluated are d through (d + num_values - 1); the results are filled into the num_values elements in the indicated result array.

evalNormal
bool NurbsSurfaceResult::eval_normal(float u, float v, LVecBase3f &normal);

Description: Computes the normal to the surface at the indicated point in parametric time. This normal vector will not necessarily be normalized, and could be zero. See also eval_point().

evalPoint
bool NurbsSurfaceResult::eval_point(float u, float v, LVecBase3f &point);

Description: Computes the point on the surface corresponding to the indicated value in parametric time. Returns true if the u, v values are valid, false otherwise.

evalSegmentExtendedPoint
float NurbsSurfaceResult::eval_segment_extended_point(int ui, int vi, float u, float v, int d) const;

Description: Evaluates the surface in n-dimensional space according to the extended vertices associated with the surface in the indicated dimension.

evalSegmentExtendedPoints
void NurbsSurfaceResult::eval_segment_extended_points(int ui, int vi, float u, float v, int d, void *result[](unsigned int size), int num_values) const;

Description: Simultaneously performs eval_extended_point on a contiguous sequence of dimensions. The dimensions evaluated are d through (d + num_values - 1); the results are filled into the num_values elements in the indicated result array.

evalSegmentNormal
void NurbsSurfaceResult::eval_segment_normal(int ui, int vi, float u, float v, LVecBase3f &normal) const;

Description: As eval_segment_point, but computes the normal to the surface at the indicated point. The normal vector will not necessarily be normalized, and could be zero.

evalSegmentPoint
void NurbsSurfaceResult::eval_segment_point(int ui, int vi, float u, float v, LVecBase3f &point) const;

Description: Evaluates the point on the surface corresponding to the indicated value in parametric time within the indicated surface segment. u and v should be in the range [0, 1].
The surface is internally represented as a number of connected (or possibly unconnected) piecewise continuous segments. The exact number of segments for a particular surface depends on the knot vector, and is returned by get_num_segments(). Normally, eval_point() is used to evaluate a point along the continuous surface, but when you care more about local continuity, you can use eval_segment_point() to evaluate the points along each segment.

getEndU
float NurbsSurfaceResult::get_end_u(void) const;

Description: Returns the last legal value of u on the surface.

getEndV
float NurbsSurfaceResult::get_end_v(void) const;

Description: Returns the last legal value of v on the surface.

getNumUSegments
int NurbsSurfaceResult::get_num_u_segments(void) const;

Description: Returns the number of piecewise continuous segments within the surface in the U direction. This number is usually not important unless you plan to call eval_segment_point().

getNumVSegments
int NurbsSurfaceResult::get_num_v_segments(void) const;

Description: Returns the number of piecewise continuous segments within the surface in the V direction. This number is usually not important unless you plan to call eval_segment_point().

getSegmentU
float NurbsSurfaceResult::get_segment_u(int ui, float u) const;

Description: Accepts a u value in the range [0, 1], and assumed to be relative to the indicated segment (as in eval_segment_point()), and returns the corresponding u value in the entire surface (as in eval_point()).

getSegmentV
float NurbsSurfaceResult::get_segment_v(int vi, float v) const;

Description: Accepts a v value in the range [0, 1], and assumed to be relative to the indicated segment (as in eval_segment_point()), and returns the corresponding v value in the entire surface (as in eval_point()).

getStartU
float NurbsSurfaceResult::get_start_u(void) const;

Description: Returns the first legal value of u on the surface. Usually this is 0.0.

getStartV
float NurbsSurfaceResult::get_start_v(void) const;

Description: Returns the first legal value of v on the surface. Usually this is 0.0.

getClassType
static TypeHandle ReferenceCount::get_class_type(void);

Undocumented function.

getRefCount
int ReferenceCount::get_ref_count(void) const;

Description: Returns the current reference count.

ref
void ReferenceCount::ref(void) const;

Description: Explicitly increments the reference count. User code should avoid using ref() and unref() directly, which can result in missed reference counts. Instead, let a PointerTo object manage the reference counting automatically.
This function is const, even though it changes the object, because generally fiddling with an object's reference count isn't considered part of fiddling with the object. An object might be const in other ways, but we still need to accurately count the number of references to it.

testRefCountIntegrity
bool ReferenceCount::test_ref_count_integrity(void) const;

Description: Does some easy checks to make sure that the reference count isn't completely bogus. Returns true if ok, false otherwise.

testRefCountNonzero
bool ReferenceCount::test_ref_count_nonzero(void) const;

Description: Does some easy checks to make sure that the reference count isn't zero, or completely bogus. Returns true if ok, false otherwise.

unref
bool ReferenceCount::unref(void) const;

Description: Explicitly decrements the reference count. Note that the object will not be implicitly deleted by unref() simply because the reference count drops to zero. (Having a member function delete itself is problematic; plus, we don't have a virtual destructor anyway.) However, see the helper function unref_delete().
User code should avoid using ref() and unref() directly, which can result in missed reference counts. Instead, let a PointerTo object manage the reference counting automatically.
This function is const, even though it changes the object, because generally fiddling with an object's reference count isn't considered part of fiddling with the object. An object might be const in other ways, but we still need to accurately count the number of references to it.
The return value is true if the new reference count is nonzero, false if it is zero.