HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HOM_AgentShapeBinding.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  * COMMENTS:
7  */
8 
9 #ifndef __HOM_AgentShapeBinding_h__
10 #define __HOM_AgentShapeBinding_h__
11 
12 #include "HOM_API.h"
13 #include "HOM_Module.h"
14 #include "HOM_PtrOrNull.h"
15 #include "HOM_Module.h"
16 
17 class HOM_AgentShape;
19 
20 SWIGOUT(%rename(AgentShapeBinding) HOM_AgentShapeBinding;)
21 // Force SWIG to output an __init__ method even though it determines this
22 // class is abstract.
23 SWIGOUT(%feature("notabstract") HOM_AgentShapeBinding;)
24 
26 {
27 public:
28 #ifdef SWIG
29 %extend
30 {
32  bool deforming, double bounds_scale = 1.0)
33  {
34  return HOM().newAgentShapeBinding(transform, shape, deforming,
35  bounds_scale);
36  }
37 
38  HOM_AgentShapeBinding(int transform, const HOM_AgentShape &shape,
39  const HOM_AgentShapeDeformer *deformer,
40  double bounds_scale = 1.0)
41  {
42  return HOM().newAgentShapeBinding(transform, shape, deformer,
43  bounds_scale);
44  }
45 
47  const HOM_AgentShapeDeformer *deformer,
48  double bounds_scale = 1.0)
49  {
50  return HOM().newAgentShapeBinding(-1, shape, deformer, bounds_scale);
51  }
52 }
53 #else
55  { HOM_CONSTRUCT_OBJECT(this) }
56 #endif
57 
59  { HOM_DESTRUCT_OBJECT(this) }
60 
61  virtual bool
64  { return !operator==(binding); }
65 
66  virtual int __hash__() const = 0;
67  virtual std::string __repr__() const = 0;
68 
69  virtual std::string shapeName() const = 0;
70  virtual int shapeId() const = 0;
71  virtual int transformId() const = 0;
72  virtual bool isDeforming() const = 0;
73  virtual double boundsScale() const = 0;
74 
75  SWIGOUT(%newobject shape;)
76  virtual HOM_AgentShape *shape() const = 0;
77 
78  SWIGOUT(%newobject deformer;)
79  virtual HOM_AgentShapeDeformer *deformer() const = 0;
80 };
81 
82 #endif
#define HOM_DESTRUCT_OBJECT(pointer)
Definition: HOM_Module.h:1138
GLuint GLenum GLenum transform
Definition: glew.h:14742
OIIO_API bool rename(string_view from, string_view to, std::string &err)
#define SWIGOUT(x)
Definition: HOM_Defines.h:24
string __repr__(VtArray< T > const &self)
Definition: wrapArray.h:349
bool operator!=(HOM_PtrOrNull< HOM_AgentShapeBinding > binding) const
virtual int __hash__() const =0
#define HOM_API
Definition: HOM_API.h:13
#define HOM_CONSTRUCT_OBJECT(pointer)
Definition: HOM_Module.h:1137
virtual HOM_AgentShapeBinding * newAgentShapeBinding(int transform, const HOM_AgentShape &shape, bool deforming, double bounds_scale)=0
GLsizei const GLchar *const * string
Definition: glew.h:1844
HOM_API HOM_Module & HOM()
bool operator==(const Mat3< T0 > &m0, const Mat3< T1 > &m1)
Equality operator, does exact floating point comparisons.
Definition: Mat3.h:590