HDK
|
#include <basisCurvesTopology.h>
Public Member Functions | |
HD_API | HdBasisCurvesTopology () |
HD_API | HdBasisCurvesTopology (const HdBasisCurvesTopology &src) |
HD_API | HdBasisCurvesTopology (const TfToken &curveType, const TfToken &curveBasis, const TfToken &curveWrap, const VtIntArray &curveVertexCounts, const VtIntArray &curveIndices) |
virtual HD_API | ~HdBasisCurvesTopology () |
VtIntArray const & | GetCurveVertexCounts () const |
Returns segment vertex counts. More... | |
VtIntArray const & | GetCurveIndices () const |
Returns indices. More... | |
size_t | GetNumCurves () const |
Returns the number of curves. More... | |
HD_API size_t | GetNumPoints () const |
Returns the number of points implied by vertex counts and indices. More... | |
TfToken | GetCurveType () const |
See class documentation for valid combination of values. More... | |
TfToken | GetCurveBasis () const |
TfToken | GetCurveWrap () const |
bool | HasIndices () const |
Does the topology use an index buffer. More... | |
virtual HD_API ID | ComputeHash () const |
Returns the hash value of this topology to be used for instancing. More... | |
HD_API bool | operator== (HdBasisCurvesTopology const &other) const |
Equality check between two basisCurves topologies. More... | |
HD_API bool | operator!= (HdBasisCurvesTopology const &other) const |
HD_API size_t | CalculateNeededNumberOfControlPoints () const |
Figure out how many vertices / control points this topology references. More... | |
HD_API size_t | CalculateNeededNumberOfVaryingControlPoints () const |
Figure out how many control points with varying data this topology needs. More... | |
Topological invisibility | |
HD_API void | SetInvisiblePoints (VtIntArray const &invisiblePoints) |
HD_API VtIntArray const & | GetInvisiblePoints () const |
HD_API void | SetInvisibleCurves (VtIntArray const &invisibleCurves) |
HD_API VtIntArray const & | GetInvisibleCurves () const |
Public Member Functions inherited from HdTopology | |
HdTopology () | |
virtual | ~HdTopology () |
Additional Inherited Members | |
Public Types inherited from HdTopology | |
typedef uint64_t | ID |
Topology data for basisCurves.
HdBasisCurvesTopology holds the raw input topology data for basisCurves
The Type, Basis and Wrap mode combined describe the curve and it's segments.
If Type == linear, the curve is a bunch of line segments and basis is ignored.
The wrap mode defines how the curve segments are specified:
If Wrap == segmented, this is equivalent to GL_LINES and curve vertex counts is 2 * number of segments (multiple entries in curve vertex array is optional).
If Wrap == nonperiodic, this is equivalent to GL_LINE_STRIP and curve counts is an array where each entry is the number of vertices in that line segment. The first and last vertex in the segment are not joined.
If Wrap == periodic, this is equivalent to GL_LINE_LOOP and curve counts is an array where each entry is the number of vertices in that line segment. An additional line is place between the first and last vertex in each segment.
If Type == cubic, the type of curve is specified by basis: The Basis can be bezier, bspline, catmullRom, or centripetalCatmullRom.
Wrap can be either periodic or nonperiodic (segmented is unsupported).
For each type of line, the generated vertex indices can pass through an optional index buffer to map the generated indices to actual indices in the vertex buffer.
Definition at line 76 of file basisCurvesTopology.h.
HD_API HdBasisCurvesTopology::HdBasisCurvesTopology | ( | ) |
HD_API HdBasisCurvesTopology::HdBasisCurvesTopology | ( | const HdBasisCurvesTopology & | src | ) |
HD_API HdBasisCurvesTopology::HdBasisCurvesTopology | ( | const TfToken & | curveType, |
const TfToken & | curveBasis, | ||
const TfToken & | curveWrap, | ||
const VtIntArray & | curveVertexCounts, | ||
const VtIntArray & | curveIndices | ||
) |
|
virtual |
HD_API size_t HdBasisCurvesTopology::CalculateNeededNumberOfControlPoints | ( | ) | const |
Figure out how many vertices / control points this topology references.
HD_API size_t HdBasisCurvesTopology::CalculateNeededNumberOfVaryingControlPoints | ( | ) | const |
Figure out how many control points with varying data this topology needs.
Returns the hash value of this topology to be used for instancing.
Implements HdTopology.
|
inline |
Definition at line 141 of file basisCurvesTopology.h.
|
inline |
Returns indices.
Definition at line 124 of file basisCurvesTopology.h.
|
inline |
See class documentation for valid combination of values.
Definition at line 140 of file basisCurvesTopology.h.
|
inline |
Returns segment vertex counts.
Definition at line 119 of file basisCurvesTopology.h.
|
inline |
Definition at line 142 of file basisCurvesTopology.h.
|
inline |
Definition at line 113 of file basisCurvesTopology.h.
|
inline |
Definition at line 103 of file basisCurvesTopology.h.
|
inline |
Returns the number of curves.
Definition at line 129 of file basisCurvesTopology.h.
|
inline |
Returns the number of points implied by vertex counts and indices.
Definition at line 135 of file basisCurvesTopology.h.
|
inline |
Does the topology use an index buffer.
Definition at line 145 of file basisCurvesTopology.h.
HD_API bool HdBasisCurvesTopology::operator!= | ( | HdBasisCurvesTopology const & | other | ) | const |
HD_API bool HdBasisCurvesTopology::operator== | ( | HdBasisCurvesTopology const & | other | ) | const |
Equality check between two basisCurves topologies.
Definition at line 108 of file basisCurvesTopology.h.
Definition at line 98 of file basisCurvesTopology.h.