HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GR_OSDSubdData.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GR_OSDSubdData.C ( GR Library, C++)
7  *
8  * COMMENTS:
9  * Class for subdivision surface data shared between GL and Vulkan.
10  */
11 #ifndef GR_OSDSubdData_h
12 #define GR_OSDSubdData_h
13 
14 #include <UT/UT_UniquePtr.h>
15 #include <GT/GT_UtilOpenSubdiv.h>
16 #include <GT/GT_Primitive.h>
17 #include "GR_API.h"
18 
19 class GR_UpdateParms;
20 
22 {
23 public:
24  void preUpdate(const GT_PrimitiveHandle &primh,
25  GR_UpdateParms &p);
26 
27  bool isReducedLOD() const { return myReducedLOD; }
28  int getSubdivisionLevel() const { return mySubdLevel; }
29  const GT_PrimitiveHandle &surface() { return mySurface; }
30 
31  void resetSubdivision();
32 
33 private:
35  GT_PrimitiveHandle mySurface;
36  int64 myVertexAttributeDataIdHash = -1;
37  bool myReducedLOD = false;
38  int mySubdLevel = 0;
39  int myTopID = 0;
40 };
41 
42 #endif
int getSubdivisionLevel() const
const GT_PrimitiveHandle & surface()
std::unique_ptr< T, Deleter > UT_UniquePtr
A smart pointer for unique ownership of dynamically allocated objects.
Definition: UT_UniquePtr.h:39
set of parameters sent to GR_Primitive::update()
#define GR_API
Definition: GR_API.h:10
long long int64
Definition: SYS_Types.h:116
bool isReducedLOD() const