VTK
dox/Rendering/Core/vtkGraphToGlyphs.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkGraphToGlyphs.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 =========================================================================*/
00015 /*-------------------------------------------------------------------------
00016   Copyright 2008 Sandia Corporation.
00017   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00018   the U.S. Government retains certain rights in this software.
00019 -------------------------------------------------------------------------*/
00032 #ifndef __vtkGraphToGlyphs_h
00033 #define __vtkGraphToGlyphs_h
00034 
00035 #include "vtkRenderingCoreModule.h" // For export macro
00036 #include "vtkPolyDataAlgorithm.h"
00037 #include "vtkSmartPointer.h" // for SP ivars
00038 
00039 class vtkDistanceToCamera;
00040 class vtkGraphToPoints;
00041 class vtkGlyph3D;
00042 class vtkGlyphSource2D;
00043 class vtkRenderer;
00044 class vtkSphereSource;
00045 
00046 class VTKRENDERINGCORE_EXPORT vtkGraphToGlyphs : public vtkPolyDataAlgorithm
00047 {
00048 public:
00049   static vtkGraphToGlyphs *New();
00050   vtkTypeMacro(vtkGraphToGlyphs, vtkPolyDataAlgorithm);
00051   void PrintSelf(ostream& os, vtkIndent indent);
00052 
00053   //BTX
00054   enum
00055     {
00056     VERTEX = 1,
00057     DASH,
00058     CROSS,
00059     THICKCROSS,
00060     TRIANGLE,
00061     SQUARE,
00062     CIRCLE,
00063     DIAMOND,
00064     SPHERE
00065     };
00066   //ETX
00067 
00069 
00073   vtkSetMacro(GlyphType, int);
00074   vtkGetMacro(GlyphType, int);
00076 
00078 
00079   vtkSetMacro(Filled, bool);
00080   vtkGetMacro(Filled, bool);
00081   vtkBooleanMacro(Filled, bool);
00083 
00085 
00088   vtkSetMacro(ScreenSize, double);
00089   vtkGetMacro(ScreenSize, double);
00091 
00093 
00094   virtual void SetRenderer(vtkRenderer* ren);
00095   virtual vtkRenderer* GetRenderer();
00097 
00099 
00101   virtual void SetScaling(bool b);
00102   virtual bool GetScaling();
00104 
00106   virtual unsigned long GetMTime();
00107 
00108 protected:
00109   vtkGraphToGlyphs();
00110   ~vtkGraphToGlyphs();
00111 
00113   int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00114 
00116   int FillInputPortInformation(int port, vtkInformation* info);
00117 
00118   //BTX
00119   vtkSmartPointer<vtkGraphToPoints> GraphToPoints;
00120   vtkSmartPointer<vtkGlyphSource2D> GlyphSource;
00121   vtkSmartPointer<vtkSphereSource> Sphere;
00122   vtkSmartPointer<vtkGlyph3D> Glyph;
00123   vtkSmartPointer<vtkDistanceToCamera> DistanceToCamera;
00124   int GlyphType;
00125   bool Filled;
00126   double ScreenSize;
00127   //ETX
00128 
00129 private:
00130   vtkGraphToGlyphs(const vtkGraphToGlyphs&);  // Not implemented.
00131   void operator=(const vtkGraphToGlyphs&);  // Not implemented.
00132 };
00133 
00134 #endif