00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkFollower.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00037 #ifndef __vtkFollower_h 00038 #define __vtkFollower_h 00039 00040 #include "vtkActor.h" 00041 00042 class vtkCamera; 00043 00044 class VTK_RENDERING_EXPORT vtkFollower : public vtkActor 00045 { 00046 public: 00047 vtkTypeMacro(vtkFollower,vtkActor); 00048 void PrintSelf(ostream& os, vtkIndent indent); 00049 00051 static vtkFollower *New(); 00052 00054 00056 virtual void SetCamera(vtkCamera*); 00057 vtkGetObjectMacro(Camera,vtkCamera); 00059 00061 00064 virtual int RenderOpaqueGeometry(vtkViewport *viewport); 00065 virtual int RenderTranslucentPolygonalGeometry(vtkViewport *viewport); 00066 virtual void Render(vtkRenderer *ren); 00068 00070 virtual int HasTranslucentPolygonalGeometry(); 00071 00073 00074 virtual void GetMatrix(vtkMatrix4x4 *m); 00075 virtual void GetMatrix(double m[16]); 00076 virtual vtkMatrix4x4* GetMatrix() 00077 {return this->vtkActor::GetMatrix();} 00079 00081 void ShallowCopy(vtkProp *prop); 00082 00083 protected: 00084 vtkFollower(); 00085 ~vtkFollower(); 00086 00087 vtkCamera *Camera; 00088 vtkActor *Device; 00089 private: 00090 // hide the two parameter Render() method from the user and the compiler. 00091 virtual void Render(vtkRenderer *, vtkMapper *) {}; 00092 private: 00093 vtkFollower(const vtkFollower&); // Not implemented. 00094 void operator=(const vtkFollower&); // Not implemented. 00095 }; 00096 00097 #endif 00098 00099 00100