36 #ifndef __vtkProperty_h
37 #define __vtkProperty_h
48 #define VTK_WIREFRAME 1
59 class vtkPropertyInternals;
101 vtkGetMacro(Lighting,
bool);
102 vtkSetMacro(Lighting,
bool);
103 vtkBooleanMacro(Lighting,
bool);
109 vtkGetMacro(Interpolation,
int);
113 const char *GetInterpolationAsString();
119 vtkGetMacro(Representation,
int);
124 const char *GetRepresentationAsString();
131 void SetColor(
double r,
double g,
double b);
134 void GetColor(
double rgb[3]);
135 void GetColor(
double &r,
double &g,
double &b);
140 vtkSetClampMacro(Ambient,
double,0.0,1.0);
141 vtkGetMacro(Ambient,
double);
146 vtkSetClampMacro(Diffuse,
double,0.0,1.0);
147 vtkGetMacro(Diffuse,
double);
152 vtkSetClampMacro(Specular,
double,0.0,1.0);
153 vtkGetMacro(Specular,
double);
158 vtkSetClampMacro(SpecularPower,
double,0.0,128.0);
159 vtkGetMacro(SpecularPower,
double);
165 vtkSetClampMacro(Opacity,
double,0.0,1.0);
166 vtkGetMacro(Opacity,
double);
174 vtkSetVector3Macro(AmbientColor,
double);
175 vtkGetVector3Macro(AmbientColor,
double);
180 vtkSetVector3Macro(DiffuseColor,
double);
181 vtkGetVector3Macro(DiffuseColor,
double);
186 vtkSetVector3Macro(SpecularColor,
double);
187 vtkGetVector3Macro(SpecularColor,
double);
194 vtkGetMacro(EdgeVisibility,
int);
195 vtkSetMacro(EdgeVisibility,
int);
196 vtkBooleanMacro(EdgeVisibility,
int);
201 vtkSetVector3Macro(EdgeColor,
double);
202 vtkGetVector3Macro(EdgeColor,
double);
209 vtkGetMacro(LineWidth,
float);
216 vtkSetMacro(LineStipplePattern,
int);
217 vtkGetMacro(LineStipplePattern,
int);
225 vtkGetMacro(LineStippleRepeatFactor,
int);
232 vtkGetMacro(PointSize,
float);
239 vtkGetMacro(BackfaceCulling,
int);
240 vtkSetMacro(BackfaceCulling,
int);
241 vtkBooleanMacro(BackfaceCulling,
int);
248 vtkGetMacro(FrontfaceCulling,
int);
249 vtkSetMacro(FrontfaceCulling,
int);
250 vtkBooleanMacro(FrontfaceCulling,
int);
261 vtkGetStringMacro(MaterialName);
266 void LoadMaterial(
const char*
name);
269 void LoadMaterialFromString(
const char* materialxml);
277 vtkSetMacro(Shading,
int);
278 vtkGetMacro(Shading,
int);
279 vtkBooleanMacro(Shading,
int);
293 virtual void AddShaderVariable(
const char *
name,
int numVars,
int *x);
294 virtual void AddShaderVariable(
const char *
name,
int numVars,
float *x);
295 virtual void AddShaderVariable(
const char *
name,
int numVars,
double *x);
300 void AddShaderVariable(
const char*
name,
int v)
302 this->AddShaderVariable(name, 1, &v);
304 void AddShaderVariable(
const char*
name,
float v)
306 this->AddShaderVariable(name, 1, &v);
308 void AddShaderVariable(
const char*
name,
double v)
310 this->AddShaderVariable(name, 1, &v);
312 void AddShaderVariable(
const char*
name,
int v1,
int v2)
317 this->AddShaderVariable(name, 2, v);
319 void AddShaderVariable(
const char*
name,
float v1,
float v2)
324 this->AddShaderVariable(name, 2, v);
326 void AddShaderVariable(
const char*
name,
double v1,
double v2)
331 this->AddShaderVariable(name, 2, v);
333 void AddShaderVariable(
const char*
name,
int v1,
int v2,
int v3)
339 this->AddShaderVariable(name, 3, v);
341 void AddShaderVariable(
const char*
name,
float v1,
float v2,
float v3)
347 this->AddShaderVariable(name, 3, v);
349 void AddShaderVariable(
const char*
name,
double v1,
double v2,
double v3)
355 this->AddShaderVariable(name, 3, v);
373 void SetTexture(
int unit,
vtkTexture* texture);
375 void RemoveTexture(
int unit);
381 void RemoveTexture(
const char*
name);
384 void RemoveAllTextures();
387 int GetNumberOfTextures();
392 virtual void ReleaseGraphicsResources(
vtkWindow *win);
400 VTK_TEXTURE_UNIT_0 = 0,
426 double AmbientColor[3];
427 double DiffuseColor[3];
428 double SpecularColor[3];
449 vtkSetStringMacro(MaterialName);
458 virtual void ReadFrameworkMaterial();
469 int GetTextureUnitAtIndex(
int index);
470 int GetTextureUnit(
const char*
name);