OpenSubdiv
Loading...
Searching...
No Matches
ptexIndices.h
Go to the documentation of this file.
1//
2// Copyright 2015 Pixar
3//
4// Licensed under the terms set forth in the LICENSE.txt file available at
5// https://opensubdiv.org/license.
6//
7#ifndef OPENSUBDIV3_FAR_PTEX_INDICES_H
8#define OPENSUBDIV3_FAR_PTEX_INDICES_H
9
10#include "../version.h"
11
13#include "../far/types.h"
14
15#include <vector>
16
17namespace OpenSubdiv {
18namespace OPENSUBDIV_VERSION {
19
20namespace Far {
21
30
31public:
32
35
38
40
43
46 int GetNumFaces() const;
47
50 int GetFaceId(Index f) const;
51
67 TopologyRefiner const &refiner,
68 int face, int quadrant,
69 int adjFaces[4], int adjEdges[4]) const;
70
72
73private:
74
75 void initializePtexIndices(TopologyRefiner const &refiner);
76
77private:
78
79 std::vector<Index> _ptexIndices;
80};
81
82
83} // end namespace Far
84
85} // end namespace OPENSUBDIV_VERSION
86using namespace OPENSUBDIV_VERSION;
87} // end namespace OpenSubdiv
88
89#endif /* OPENSUBDIV3_FAR_PTEX_INDICES_H */
Object used to compute and query ptex face indices.
Definition ptexIndices.h:29
int GetFaceId(Index f) const
Returns the ptex face index given a coarse face 'f' or -1.
PtexIndices(TopologyRefiner const &refiner)
Constructor.
void GetAdjacency(TopologyRefiner const &refiner, int face, int quadrant, int adjFaces[4], int adjEdges[4]) const
Returns ptex face adjacency information for a given coarse face.
int GetNumFaces() const
Returns the number of ptex faces in the mesh.
Stores topology data for a specified set of refinement options.