24 #ifndef OPENSUBDIV3_VTR_FVAR_LEVEL_H 25 #define OPENSUBDIV3_VTR_FVAR_LEVEL_H 27 #include "../version.h" 29 #include "../sdc/types.h" 30 #include "../sdc/crease.h" 31 #include "../sdc/options.h" 32 #include "../vtr/types.h" 33 #include "../vtr/level.h" 41 namespace OPENSUBDIV_VERSION {
90 void clear() { std::memset(
this, 0,
sizeof(
ETag)); }
246 Level const & _level;
252 bool _hasLinearBoundaries;
253 bool _hasDependentSharpness;
268 std::vector<Index> _faceVertValues;
271 std::vector<ETag> _edgeTags;
274 std::vector<Sibling> _vertSiblingCounts;
275 std::vector<int> _vertSiblingOffsets;
276 std::vector<Sibling> _vertFaceSiblings;
279 std::vector<Index> _vertValueIndices;
280 std::vector<ValueTag> _vertValueTags;
281 std::vector<CreaseEndPair> _vertValueCreaseEnds;
299 return IndexArray(&_faceVertValues[vOffset], vCount);
314 return SiblingArray(&_vertFaceSiblings[vOffset], vCount);
329 return IndexArray(&_vertValueIndices[vOffset], vCount);
365 if (_level.
getDepth() > 0)
return valueIndex;
368 while (_vertValueIndices[vvIndex] != valueIndex) {
389 if (this->_mismatch) {
390 if (this->isCorner()) {
394 levelTag.
_corner = !this->_infIrregular && !this->_infSharpEdges;
415 using namespace OPENSUBDIV_VERSION;
void getVertexCreaseEndValues(Index vIndex, Sibling sibling, Index endValues[2]) const
Level::ETag combineWithLevelETag(Level::ETag) const
bool hasLinearBoundaries() const
Vtr::ConstArray< CreaseEndPair > ConstCreaseEndPairArray
bool hasSmoothBoundaries() const
CreaseEndPair getValueCreaseEndPair(Index valueIndex) const
int getOffsetOfVertexFaces(Index vertIndex) const
int getNumFaceVertices(Index faceIndex) const
FVarLevel(Level const &level)
Vtr::Array< CreaseEndPair > CreaseEndPairArray
Index getVertexValue(Index v, Sibling i=0) const
void buildFaceVertexSiblingsFromVertexFaceSiblings(std::vector< Sibling > &fvSiblings) const
void setOptions(Sdc::Options const &options)
ETag getEdgeTag(Index eIndex) const
int getNumVertexFaces(Index vertIndex) const
Level const & getLevel() const
ValueTagSize _infIrregular
void gatherValueSpans(Index vIndex, ValueSpan *vValueSpans) const
int getNumFaceValuesTotal() const
void completeTopologyFromFaceValues(int regBoundaryValence)
Array< Index > IndexArray
bool hasCreaseEnds() const
unsigned char ValueTagSize
ConstCreaseEndPairArray getVertexValueCreaseEnds(Index vIndex) const
ConstArray< Index > ConstIndexArray
ConstSiblingArray getVertexFaceSiblings(Index vIndex) const
Index findVertexValueIndex(Index vertexIndex, Index valueIndex) const
Vtr::ConstArray< ValueTag > ConstValueTagArray
ValueTag getFaceCompositeValueTag(Index faceIndex) const
bool valueTopologyMatches(Index valueIndex) const
void getEdgeFaceValues(Index eIndex, int fIncToEdge, Index valuesPerVert[2]) const
Index getVertexValueOffset(Index v, Sibling i=0) const
bool hasInfSharpEdges() const
All supported options applying to subdivision scheme.
void resizeVertexValues(int numVertexValues)
ConstLocalIndexArray ConstSiblingArray
int getNumVertexValues(Index v) const
unsigned short LocalIndex
bool hasCreaseEnds() const
Level::VTag combineWithLevelVTag(Level::VTag) const
int getOffsetOfFaceVertices(Index faceIndex) const
bool edgeTopologyMatches(Index eIndex) const
void getFaceValueTags(Index faceIndex, ValueTag valueTags[]) const
ValueTag getValueTag(Index valueIndex) const
void getVertexEdgeValues(Index vIndex, Index valuesPerEdge[]) const
void initializeFaceValuesFromFaceVertices()
ConstValueTagArray getVertexValueTags(Index vIndex) const
ConstIndexArray getFaceValues(Index fIndex) const
void initializeFaceValuesFromVertexFaceSiblings()
Vtr::Array< ValueTag > ValueTagArray
Sdc::Options getOptions() const
ValueTagSize _infSharpEdges
void resizeValues(int numValues)
ValueTagSize _nonManifold
bool hasInfIrregularity() const
ConstIndexArray getVertexValues(Index vIndex) const
LocalIndexArray SiblingArray