00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00033
#ifndef __vtkProp_h
00034
#define __vtkProp_h
00035
00036
#include "vtkObject.h"
00037
00038
class vtkAssemblyPath;
00039
class vtkAssemblyPaths;
00040
class vtkMatrix4x4;
00041
class vtkPropCollection;
00042
class vtkViewport;
00043
class vtkWindow;
00044
00045 class VTK_COMMON_EXPORT vtkProp :
public vtkObject
00046 {
00047
public:
00048 vtkTypeRevisionMacro(vtkProp,
vtkObject);
00049
void PrintSelf(ostream& os,
vtkIndent indent);
00050
00052
00055 virtual void GetActors(
vtkPropCollection *) {}
00056 virtual void GetActors2D(
vtkPropCollection *) {}
00057 virtual void GetVolumes(
vtkPropCollection *) {}
00059
00061
00062 vtkSetMacro(Visibility,
int);
00063 vtkGetMacro(Visibility,
int);
00064 vtkBooleanMacro(Visibility,
int);
00066
00068
00070 vtkSetMacro(Pickable,
int);
00071 vtkGetMacro(Pickable,
int);
00072 vtkBooleanMacro(Pickable,
int);
00074
00076
virtual void Pick();
00077
00079
00085 vtkSetMacro(Dragable,
int);
00086 vtkGetMacro(Dragable,
int);
00087 vtkBooleanMacro(Dragable,
int);
00089
00094 virtual unsigned long GetRedrawMTime() {
return this->
GetMTime();}
00095
00098 virtual double *GetBounds() {
return NULL;}
00099
00101
virtual void ShallowCopy(vtkProp *prop);
00102
00104
00115
virtual void InitPathTraversal();
00116
virtual vtkAssemblyPath *GetNextPath();
00117 virtual int GetNumberOfPaths() {
return 1;}
00119
00121
00124 virtual void PokeMatrix(
vtkMatrix4x4 *vtkNotUsed(matrix)) {}
00125 virtual vtkMatrix4x4 *GetMatrix() {
return NULL;}
00127
00128
00130
00141 virtual int RenderOpaqueGeometry(
vtkViewport *) {
return 0; }
00142 virtual int RenderTranslucentGeometry(
vtkViewport *) {
return 0; }
00143 virtual int RenderOverlay(
vtkViewport *) {
return 0; }
00145
00150 virtual void ReleaseGraphicsResources(
vtkWindow *) {}
00151
00153
00163 virtual double GetEstimatedRenderTime(
vtkViewport * )
00164 {
return this->EstimatedRenderTime; }
00165 virtual double GetEstimatedRenderTime(){
return this->EstimatedRenderTime; }
00167
00169
00173 virtual void SetEstimatedRenderTime(
double t)
00174 {this->EstimatedRenderTime = t; this->SavedEstimatedRenderTime = t;}
00176
00178
00183 virtual void RestoreEstimatedRenderTime()
00184 { this->EstimatedRenderTime = this->SavedEstimatedRenderTime; }
00186
00187
00189
00199 virtual void AddEstimatedRenderTime(
double t,
vtkViewport *vtkNotUsed(vp))
00200 {this->EstimatedRenderTime+=t;}
00202
00204
00211 virtual void SetAllocatedRenderTime(
double t,
vtkViewport *vtkNotUsed(v))
00212 {
00213 this->AllocatedRenderTime = t;
00214 this->SavedEstimatedRenderTime = this->EstimatedRenderTime;
00215 this->EstimatedRenderTime = 0.0;
00216 }
00218
00220
00222 vtkGetMacro(AllocatedRenderTime,
double);
00224
00226
00230 void SetRenderTimeMultiplier(
double t ) { this->RenderTimeMultiplier = t; }
00231 vtkGetMacro(RenderTimeMultiplier,
double);
00233
00237
virtual void BuildPaths(
vtkAssemblyPaths *paths,
vtkAssemblyPath *path);
00238
00240
00241 vtkGetMacro(NumberOfConsumers,
int);
00243
00245
00246
void AddConsumer(
vtkObject *c);
00247
void RemoveConsumer(
vtkObject *c);
00248
vtkObject *GetConsumer(
int i);
00249
int IsConsumer(
vtkObject *c);
00251
00252
00253
00254
protected:
00255 vtkProp();
00256 ~vtkProp();
00257
00258 int Visibility;
00259 int Pickable;
00260 int Dragable;
00261
00262 double AllocatedRenderTime;
00263 double EstimatedRenderTime;
00264 double SavedEstimatedRenderTime;
00265 double RenderTimeMultiplier;
00266
00267
00268 int NumberOfConsumers;
00269 vtkObject **Consumers;
00270
00271
00272
00273 vtkAssemblyPaths *Paths;
00274
00275
private:
00276 vtkProp(
const vtkProp&);
00277
void operator=(
const vtkProp&);
00278 };
00279
00280
#endif
00281
00282