HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GU_TextureUnwrap.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: GU Library (C++)
7  *
8  * COMMENTS: Texture coordinate unwrapping code.
9  *
10  */
11 #ifndef __GU_TextureUnwrap_h__
12 #define __GU_TextureUnwrap_h__
13 
14 #include "GU_API.h"
15 #include <GA/GA_Handle.h>
16 #include <UT/UT_Matrix3.h>
17 #include <UT/UT_StringHolder.h>
18 #include <UT/UT_Vector3Array.h>
19 
20 class GA_PrimitiveGroup;
21 class GU_Detail;
22 
24 {
25 public:
27  {
28  LAYOUT_STRIP = 0,
29  LAYOUT_SQUARE = 1
30  };
31 
32  enum ScaleType
33  {
34  SCALE_NONE = 0,
35  SCALE_UNIFORM = 1,
36  SCALE_STRETCH = 2
37  };
38 
40 
41  void initializeTetrahedron();
42  void initialize5();
43  void initializeCube();
44  void initialize8();
45 
46  void initializeGeometry(const GU_Detail *gdp,
47  const GA_PrimitiveGroup *group);
48 
49  // Build polygon geometry representation of the planes being
50  // projected onto.
51  static void buildGeometry4(GU_Detail *gdp);
52  static void buildGeometry5(GU_Detail *gdp);
53  static void buildGeometry6(GU_Detail *gdp);
54  static void buildGeometry8(GU_Detail *gdp);
55 
57 
59 
62 
65 
66  float mySpacing;
67 };
68 
69 
71 {
72 public:
73 
76 
77 
78  // Performs the extrusion
79  void unwrap(const GU_TextureUnwrapParms &parms);
80 
81 private:
82  GU_Detail *myGdp;
83 };
84 
85 #endif
UT_Vector3Array myPlaneXAxes
const GA_PrimitiveGroup * myGroup
#define GU_API
Definition: GU_API.h:14
UT_Vector3Array myPlaneNormals