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"
40 namespace OpenSubdiv {
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) {
397 if (this->isCorner()) {
402 if (this->isCrease() || this->isSemiSharp()) {
409 levelTag.
_corner = !this->_infIrregular && !this->_infSharpEdges;
426 using namespace OPENSUBDIV_VERSION;
void resizeValues(int numValues)
void resizeVertexValues(int numVertexValues)
ValueTag getFaceCompositeValueTag(Index faceIndex) const
void buildFaceVertexSiblingsFromVertexFaceSiblings(std::vector< Sibling > &fvSiblings) const
void completeTopologyFromFaceValues(int regBoundaryValence)
Vtr::Array< CreaseEndPair > CreaseEndPairArray
int getNumVertexValues(Index v) const
LocalIndexArray SiblingArray
void getVertexCreaseEndValues(Index vIndex, Sibling sibling, Index endValues[2]) const
Level const & getLevel() const
ConstArray< Index > ConstIndexArray
bool edgeTopologyMatches(Index eIndex) const
void initializeFaceValuesFromVertexFaceSiblings()
void getFaceValueTags(Index faceIndex, ValueTag valueTags[]) const
ConstIndexArray getVertexValues(Index vIndex) const
bool hasInfIrregularity() const
ETag getEdgeTag(Index eIndex) const
bool hasLinearBoundaries() const
Index getVertexValueOffset(Index v, Sibling i=0) const
void getEdgeFaceValues(Index eIndex, int fIncToEdge, Index valuesPerVert[2]) const
Vtr::Array< ValueTag > ValueTagArray
void initializeFaceValuesFromFaceVertices()
ValueTagSize _infSharpEdges
ConstIndexArray getFaceValues(Index fIndex) const
Index getVertexValue(Index v, Sibling i=0) const
CreaseEndPair getValueCreaseEndPair(Index valueIndex) const
Vtr::ConstArray< CreaseEndPair > ConstCreaseEndPairArray
bool hasSmoothBoundaries() const
bool hasCreaseEnds() const
FVarLevel(Level const &level)
int getNumVertexFaces(Index vertIndex) const
Level::VTag combineWithLevelVTag(Level::VTag) const
ConstValueTagArray getVertexValueTags(Index vIndex) const
All supported options applying to subdivision scheme.
bool hasCreaseEnds() const
ValueTagSize _nonManifold
int getNumFaceVertices(Index faceIndex) const
Sdc::Options getOptions() const
ConstSiblingArray getVertexFaceSiblings(Index vIndex) const
void gatherValueSpans(Index vIndex, ValueSpan *vValueSpans) const
int getOffsetOfVertexFaces(Index vertIndex) const
bool valueTopologyMatches(Index valueIndex) const
Array< Index > IndexArray
int getNumFaceValuesTotal() const
unsigned short LocalIndex
int getOffsetOfFaceVertices(Index faceIndex) const
ValueTagSize _infIrregular
ConstCreaseEndPairArray getVertexValueCreaseEnds(Index vIndex) const
Vtr::ConstArray< ValueTag > ConstValueTagArray
Index findVertexValueIndex(Index vertexIndex, Index valueIndex) const
ValueTag getValueTag(Index valueIndex) const
void setOptions(Sdc::Options const &options)
Level::ETag combineWithLevelETag(Level::ETag) const
unsigned char ValueTagSize
bool hasInfSharpEdges() const
void getVertexEdgeValues(Index vIndex, Index valuesPerEdge[]) const
ConstLocalIndexArray ConstSiblingArray