HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GT_GEOPrimCaptureRegions.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: GT_GEOPrimCaptureRegions.h ( GT Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __GT_GEOPrimCaptureRegions__
12 #define __GT_GEOPrimCaptureRegions__
13 
14 #include "GT_API.h"
15 #include "GT_PrimQuadricMesh.h"
16 #include "GT_TransformArray.h"
17 
18 /// A virtual container used by sphere, circle and tube meshes
20 {
21 public:
22  /// Default c-tor
24  : myTaperX()
25  , myTaperY()
27  { }
28 
30  : GT_PrimQuadricMesh(src)
31  , myTaperX(src.myTaperX)
32  , myTaperY(src.myTaperY)
33  , myBottomCap(src.myBottomCap)
34  , myTopCap(src.myTopCap)
35  {
36  }
37 
38  /// Construct a full list of quadrics
40  const GT_DataArrayHandle &taperx,
41  const GT_DataArrayHandle &tapery,
42  const GT_DataArrayHandle &bcap,
43  const GT_DataArrayHandle &tcap,
44  const GT_AttributeListHandle &vertex,
45  const GT_AttributeListHandle &detail,
46  const GT_TransformArrayHandle &xforms)
47  : myTaperX(taperx)
48  , myTaperY(tapery)
49  , myBottomCap(bcap)
50  , myTopCap(tcap)
51  , GT_PrimQuadricMesh(vertex, detail, xforms)
52  {
53  }
54  virtual ~GT_GEOPrimCaptureRegions();
55 
56  virtual const char *className() const { return "GT_GEOPrimCaptureRegions"; }
57  virtual int getPrimitiveType() const
58  { return GT_PRIM_CAPTURE_REGIONS; }
60  { return new GT_GEOPrimCaptureRegions(*this); }
61  virtual GT_PrimitiveHandle doHarden() const;
62 
63  virtual bool refine(GT_Refine &refiner,
64  const GT_RefineParms *parms) const;
65 
66  GT_Size entries() const { return getQuadricCount(); }
67  const GT_DataArrayHandle &taperX() const { return myTaperX; }
68  const GT_DataArrayHandle &taperY() const { return myTaperY; }
69  const GT_DataArrayHandle &bottomCap() const { return myBottomCap; }
70  const GT_DataArrayHandle &topCap() const { return myTopCap; }
71 
72 protected:
73  virtual void getQBounds(UT_BoundingBox &box) const;
76  const GT_TransformHandle &x,
77  const GT_RefineParms *parms) const;
78  /// Refine to a curve mesh. Each region will be composed of 4 individual
79  /// curves.
80  GT_PrimitiveHandle refineToCurves(const GT_RefineParms *parms) const;
81 
86 };
87 
88 #endif
const GT_DataArrayHandle & taperX() const
virtual GT_PrimitiveHandle doSoftCopy() const
const GT_DataArrayHandle & taperY() const
virtual GT_PrimitiveHandle makeQuadric(GT_Size index, const GT_AttributeListHandle &h, const GT_TransformHandle &x, const GT_RefineParms *parms) const =0
Sub-class method to make an individual primitive.
virtual int getPrimitiveType() const
#define GT_API
Definition: GT_API.h:11
const GT_DataArrayHandle & bottomCap() const
virtual bool refine(GT_Refine &refiner, const GT_RefineParms *parms) const
GT_Size getQuadricCount() const
virtual const char * className() const
A virtual container used by sphere, circle and tube meshes.
virtual void getQBounds(UT_BoundingBox &box) const =0
A virtual container used by sphere, circle and tube meshes.
virtual GT_PrimitiveHandle doHarden() const
Processes primitives generated by refinement process.
Definition: GT_Refine.h:20
GLfloat GLfloat GLfloat GLfloat h
Definition: glcorearb.h:2001
GT_GEOPrimCaptureRegions()
Default c-tor.
GLuint index
Definition: glcorearb.h:785
GLint GLenum GLint x
Definition: glcorearb.h:408
const GT_DataArrayHandle & topCap() const
GT_GEOPrimCaptureRegions(const GT_DataArrayHandle &taperx, const GT_DataArrayHandle &tapery, const GT_DataArrayHandle &bcap, const GT_DataArrayHandle &tcap, const GT_AttributeListHandle &vertex, const GT_AttributeListHandle &detail, const GT_TransformArrayHandle &xforms)
Construct a full list of quadrics.
int64 GT_Size
Definition: GT_Types.h:109
GLenum src
Definition: glcorearb.h:1792
GT_GEOPrimCaptureRegions(const GT_GEOPrimCaptureRegions &src)