HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
OBJ_ReLightProxy.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: OBJ_ReLightProxy.h ( OBJ Library, C++)
7  *
8  * COMMENTS:
9  * Stand-in proxy for OBJ_ReLight. If OBJ_ReLight is not loaded (i.e.
10  * non-graphical apps), then the proxy does nothing.
11  */
12 
13 #ifndef __OBJ_ReLightProxy__
14 #define __OBJ_ReLightProxy__
15 
16 #include "OBJ_API.h"
17 
18 #include "OBJ_Light.h"
19 #include <UT/UT_Vector3.h>
20 
21 class OBJ_Ambient;
22 class OBJ_ReLightProxy;
23 class RE_Light;
24 class UT_Ramp;
25 
26 typedef OBJ_ReLightProxy *(*OBJ_ReLightProxyCreateFunc)
27  (OBJ_Ambient *obj_light);
28 
29 // ==========================================================================
30 // OBJ_ReLightProxy declaration.
31 // ==========================================================================
33 {
34 public:
35  virtual ~OBJ_ReLightProxy();
36 
37  virtual RE_Light *getLight();
38 
39  static OBJ_ReLightProxy *create(OBJ_Ambient *obj_light);
40  static void registerCreateFunc(OBJ_ReLightProxyCreateFunc create_func);
41 
42  // Proxies for methods on the OBJ_ReLight object.
43  // In this base class, these proxies are just stubs.
44  virtual void enable(bool e);
45  virtual void setInfinite(int onoff);
46  virtual void setAmbient(int onoff);
47  virtual void setCone(int onoff);
48  virtual void setName(const char *name);
49  virtual void setPosition(const UT_Vector3 &p);
50  virtual void setDirection(const UT_Vector3 &d);
51  virtual void setOrientation(UT_Matrix3 &orient);
52  virtual void setColor(const UT_Vector3 &c);
53  virtual void setConeAttrib(float a, float d, float r);
54  virtual void setProjectMap(const char *name, const char *relativeTo);
55  virtual void setProjectMapClamp(int onoff);
56  virtual void setShadowed(bool onoff);
57  virtual void setShadowIntensity(float i);
58  virtual void setShadowBias(float b);
59  virtual void setShadowBlur(float b);
60  virtual void setShadowQuality(float q);
61  virtual void setShadowMask(const char *m);
62  virtual void setTransform(const UT_Matrix4 &m);
63  virtual void setFocalLength(float focal);
64  virtual void setAperture(float aper);
65  virtual void setNearDistance(float znear);
66  virtual void setFarDistance(float zfar);
67  virtual int isInfinite() const;
68  virtual void setOrthoWidth(float width);
69  virtual void setDiffuse(int onoff);
70  virtual void setSpecular(int onoff);
71  virtual void setArea(bool onoff);
72  virtual void setGlobalIllumination(bool onoff);
73  virtual void setPortal(bool onoff);
74  virtual void setAreaSide(bool single, bool reverse);
75  virtual void setAreaAxes(const UT_Vector3F &axes);
76  virtual void setSurfaceArea(float area);
77  virtual void setAreaShape(OBJ_LightAreaShape shape);
78  virtual void setAreaTransform(UT_Matrix4 t);
79  virtual void setEnvironmentMap(const char *name, const char *relativeTo);
80  virtual void setEnvironment(bool onoff);
81  virtual void setEnvironmentMipmap(bool onoff);
82  virtual void setEnvironmentCone(float angle);
83  virtual bool isEnvironmentLight() const;
84  virtual void setAttenuation(float constant, float linear, float quadratic);
85  virtual void setAttenuationRange(float near_dist, float far_dist);
86  virtual void setAttenuationRamp(
87  const UT_Ramp *ramp, float start_dist, float end_dist);
88  virtual void setLightShadowMapSize(int s);
89  virtual void setFogIntensity(float i);
90  virtual void setFogScatter(float para, float perp);
91 
92 protected:
94 
95 private:
96  void verifySubclassOverride() const;
97 };
98 
99 
100 // ==========================================================================
101 // OBJ_ReLightProxy stub implementation.
102 // ==========================================================================
103 
105 {
106  verifySubclassOverride();
107  return NULL;
108 }
109 
110 inline void OBJ_ReLightProxy::enable(bool e)
111 { verifySubclassOverride(); }
112 
113 inline void OBJ_ReLightProxy::setInfinite(int onoff)
114 { verifySubclassOverride(); }
115 
116 inline void OBJ_ReLightProxy::setAmbient(int onoff)
117 { verifySubclassOverride(); }
118 
119 inline void OBJ_ReLightProxy::setCone(int onoff)
120 { verifySubclassOverride(); }
121 
122 inline void OBJ_ReLightProxy::setName(const char *name)
123 { verifySubclassOverride(); }
124 
126 { verifySubclassOverride(); }
127 
129 { verifySubclassOverride(); }
130 
132 { verifySubclassOverride(); }
133 
135 { verifySubclassOverride(); }
136 
137 inline void OBJ_ReLightProxy::setConeAttrib(float a, float d, float r)
138 { verifySubclassOverride(); }
139 
141  const char *name, const char *relativeTo)
142 { verifySubclassOverride(); }
143 
145 { verifySubclassOverride(); }
146 
147 inline void OBJ_ReLightProxy::setShadowed(bool onoff)
148 { verifySubclassOverride(); }
149 
151 { verifySubclassOverride(); }
152 
154 { verifySubclassOverride(); }
155 
157 { verifySubclassOverride(); }
158 
160 { verifySubclassOverride(); }
161 
162 inline void OBJ_ReLightProxy::setShadowMask(const char *m)
163 { verifySubclassOverride(); }
164 
166 { verifySubclassOverride(); }
167 
168 inline void OBJ_ReLightProxy::setFocalLength(float focal)
169 { verifySubclassOverride(); }
170 
171 inline void OBJ_ReLightProxy::setAperture(float aper)
172 { verifySubclassOverride(); }
173 
174 inline void OBJ_ReLightProxy::setNearDistance(float znear)
175 { verifySubclassOverride(); }
176 
177 inline void OBJ_ReLightProxy::setFarDistance(float zfar)
178 { verifySubclassOverride(); }
179 
180 inline int OBJ_ReLightProxy::isInfinite() const
181 {
182  verifySubclassOverride();
183  return 0;
184 }
185 
187 { verifySubclassOverride(); }
188 
189 inline void OBJ_ReLightProxy::setDiffuse(int onoff)
190 { verifySubclassOverride(); }
191 
192 inline void OBJ_ReLightProxy::setSpecular(int onoff)
193 { verifySubclassOverride(); }
194 
195 inline void OBJ_ReLightProxy::setArea(bool onoff)
196 { verifySubclassOverride(); }
197 
199 { verifySubclassOverride(); }
200 
201 inline void OBJ_ReLightProxy::setPortal(bool onoff)
202 { verifySubclassOverride(); }
203 
204 inline void OBJ_ReLightProxy::setAreaSide(bool single, bool reverse)
205 { verifySubclassOverride(); }
206 
208 { verifySubclassOverride(); }
209 
211 { verifySubclassOverride(); }
212 
214 { verifySubclassOverride(); }
215 
217 { verifySubclassOverride(); }
218 
220  const char *name, const char *relativeTo)
221 { verifySubclassOverride(); }
222 
223 inline void OBJ_ReLightProxy::setEnvironment(bool onoff)
224 { verifySubclassOverride(); }
225 
227 { verifySubclassOverride(); }
228 
230 { verifySubclassOverride(); }
231 
233 {
234  verifySubclassOverride();
235  return false;
236 }
237 
239  float constant, float linear, float quadratic)
240 { verifySubclassOverride(); }
241 
243  float near_dist, float far_dist)
244 { verifySubclassOverride(); }
245 
247  const UT_Ramp *ramp, float start_dist, float end_dist)
248 { verifySubclassOverride(); }
249 
251 { verifySubclassOverride(); }
252 
254 { verifySubclassOverride(); }
255 
256 inline void OBJ_ReLightProxy::setFogScatter(float,float)
257 { verifySubclassOverride(); }
258 
259 #endif
GLdouble s
Definition: glew.h:1390
virtual void setEnvironment(bool onoff)
virtual void setLightShadowMapSize(int s)
GLuint const GLchar * name
Definition: glew.h:1814
virtual void setShadowIntensity(float i)
virtual void setFocalLength(float focal)
virtual void setAreaTransform(UT_Matrix4 t)
virtual void setSurfaceArea(float area)
virtual void setEnvironmentCone(float angle)
GLint GLint GLint GLint GLint GLint GLsizei width
Definition: glew.h:1252
virtual void setTransform(const UT_Matrix4 &m)
virtual bool isEnvironmentLight() const
GLboolean GLboolean GLboolean GLboolean a
Definition: glew.h:9477
virtual void setShadowed(bool onoff)
virtual void setPortal(bool onoff)
void reverse(I begin, I end)
Definition: pugixml.cpp:7190
const GLdouble * m
Definition: glew.h:9124
OBJ_ReLightProxy *(* OBJ_ReLightProxyCreateFunc)(OBJ_Ambient *obj_light)
GLdouble angle
Definition: glew.h:9135
virtual void setAreaShape(OBJ_LightAreaShape shape)
virtual void setAttenuationRamp(const UT_Ramp *ramp, float start_dist, float end_dist)
virtual void setNearDistance(float znear)
virtual void setProjectMapClamp(int onoff)
virtual void setEnvironmentMipmap(bool onoff)
GLdouble GLdouble GLdouble GLdouble q
Definition: glew.h:1414
virtual void setFogScatter(float para, float perp)
virtual void setName(const char *name)
virtual void enable(bool e)
virtual void setAttenuation(float constant, float linear, float quadratic)
virtual void setProjectMap(const char *name, const char *relativeTo)
virtual void setArea(bool onoff)
virtual void setAperture(float aper)
OBJ_LightAreaShape
Definition: OBJ_Light.h:29
bool isInfinite(const float x)
Return true if x is an infinity value (either positive infinity or negative infinity).
Definition: Math.h:376
const GLfloat * c
Definition: glew.h:16296
virtual void setAmbient(int onoff)
virtual void setAreaSide(bool single, bool reverse)
virtual void setInfinite(int onoff)
virtual void setConeAttrib(float a, float d, float r)
GA_API const UT_StringHolder orient
virtual void setOrientation(UT_Matrix3 &orient)
virtual void setShadowMask(const char *m)
GLdouble GLdouble GLdouble b
Definition: glew.h:9122
GLfloat GLfloat p
Definition: glew.h:16321
virtual void setFogIntensity(float i)
virtual void setDiffuse(int onoff)
virtual void setCone(int onoff)
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
virtual int isInfinite() const
virtual void setShadowBlur(float b)
virtual void setSpecular(int onoff)
virtual void setEnvironmentMap(const char *name, const char *relativeTo)
GLdouble GLdouble GLdouble r
Definition: glew.h:1406
virtual void setGlobalIllumination(bool onoff)
virtual void setPosition(const UT_Vector3 &p)
virtual void setAreaAxes(const UT_Vector3F &axes)
virtual void setFarDistance(float zfar)
virtual void setDirection(const UT_Vector3 &d)
#define OBJ_API
Definition: OBJ_API.h:10
virtual void setShadowBias(float b)
virtual void setAttenuationRange(float near_dist, float far_dist)
virtual void setOrthoWidth(float width)
GLboolean enable
Definition: glew.h:2745
GLdouble GLdouble t
Definition: glew.h:1398
virtual void setColor(const UT_Vector3 &c)
virtual RE_Light * getLight()
GA_API const UT_StringHolder area
virtual void setShadowQuality(float q)