• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

dox/Geovis/vtkGeoGraphRepresentation.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkGeoGraphRepresentation.h,v $
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 -------------------------------------------------------------------------*/
00035 #ifndef __vtkGeoGraphRepresentation_h
00036 #define __vtkGeoGraphRepresentation_h
00037 
00038 #include "vtkDataRepresentation.h"
00039 #include "vtkSmartPointer.h" // for ivars
00040 
00041 class vtkActor;
00042 class vtkActor2D;
00043 class vtkAlgorithmOutput;
00044 class vtkDataObject;
00045 class vtkEdgeCenters;
00046 class vtkEdgeLayout;
00047 class vtkEdgeLayoutStrategy;
00048 class vtkExtractSelectedGraph;
00049 class vtkGeoAssignCoordinates;
00050 class vtkGeoEdgeStrategy;
00051 class vtkGraphMapper;
00052 class vtkGraphToPolyData;
00053 class vtkLabeledDataMapper;
00054 class vtkPointSetToLabelHierarchy;
00055 class vtkLabelPlacer;
00056 class vtkLabelSizeCalculator;
00057 class vtkMaskPoints;
00058 class vtkPolyDataMapper;
00059 class vtkSelection;
00060 class vtkSelectVisiblePoints;
00061 class vtkAbstractTransform;
00062 class vtkTransformPolyDataFilter;
00063 class vtkView;
00064 class vtkViewTheme;
00065 
00066 class VTK_GEOVIS_EXPORT vtkGeoGraphRepresentation : public vtkDataRepresentation
00067 {
00068 public:
00069   static vtkGeoGraphRepresentation *New();
00070   vtkTypeRevisionMacro(vtkGeoGraphRepresentation, vtkDataRepresentation);
00071   void PrintSelf(ostream& os, vtkIndent indent);
00072   
00074   virtual void SetInputConnection(vtkAlgorithmOutput* conn);
00075 
00077 
00078   virtual void SetVertexLabelArrayName(const char* name);
00079   virtual const char* GetVertexLabelArrayName();
00081 
00083 
00084   virtual void SetVertexLabelVisibility(bool b);
00085   virtual bool GetVertexLabelVisibility();
00086   virtual void VertexLabelVisibilityOn() { this->SetVertexLabelVisibility(true); }
00087   virtual void VertexLabelVisibilityOff() { this->SetVertexLabelVisibility(false); }
00089 
00091 
00092   virtual void SetExplodeFactor(double factor);
00093   virtual double GetExplodeFactor();
00095 
00097 
00098   virtual void SetNumberOfSubdivisions(int num);
00099   virtual int GetNumberOfSubdivisions();
00101 
00103 
00104   virtual void SetLatitudeArrayName(const char* name);
00105   virtual const char* GetLatitudeArrayName();
00107 
00109 
00110   virtual void SetLongitudeArrayName(const char* name);
00111   virtual const char* GetLongitudeArrayName();
00113 
00115 
00116   void SetVertexLabelFontSize(int size);
00117   int GetVertexLabelFontSize();
00119 
00121 
00122   void SetColorVertices(bool b);
00123   bool GetColorVertices();
00124   vtkBooleanMacro(ColorVertices, bool);
00126 
00128 
00129   void SetVertexColorArrayName(const char* name);
00130   const char* GetVertexColorArrayName();
00132 
00134 
00135   void SetEdgeLabelVisibility(bool b);
00136   bool GetEdgeLabelVisibility();
00137   vtkBooleanMacro(EdgeLabelVisibility, bool);
00139 
00141 
00142   void SetEdgeLabelArrayName(const char* name);
00143   const char* GetEdgeLabelArrayName();
00145 
00147 
00148   virtual void SetEdgeLayoutStrategy(vtkEdgeLayoutStrategy* strategy);
00149   virtual vtkEdgeLayoutStrategy* GetEdgeLayoutStrategy();
00150   virtual void SetEdgeLayoutStrategyToGeo();
00151   virtual void SetEdgeLayoutStrategyToArcParallel();
00153 
00155 
00156   void SetEdgeLabelFontSize(int size);
00157   int GetEdgeLabelFontSize();
00159 
00161 
00162   void SetColorEdges(bool b);
00163   bool GetColorEdges();
00164   vtkBooleanMacro(ColorEdges, bool);
00166 
00168 
00169   void SetEdgeColorArrayName(const char* name);
00170   const char* GetEdgeColorArrayName();
00172 
00174 
00176   void SetTransform(vtkAbstractTransform* trans);
00177   vtkAbstractTransform* GetTransform();
00179 
00181   void ApplyViewTheme(vtkViewTheme* theme);
00182 
00184   virtual void PrepareForRendering();
00185 
00186 protected:
00187   vtkGeoGraphRepresentation();
00188   ~vtkGeoGraphRepresentation();
00189 
00191 
00193   vtkSetStringMacro(LabelArrayName);
00194   vtkGetStringMacro(LabelArrayName);
00196 
00199   virtual bool AddToView(vtkView* view);
00200 
00203   virtual bool RemoveFromView(vtkView* view);
00204 
00208   virtual vtkSelection* ConvertSelection(vtkView* view, vtkSelection* selection);
00209 
00210   //BTX
00212 
00213   vtkSmartPointer<vtkGeoAssignCoordinates>    AssignCoordinates;
00214   vtkSmartPointer<vtkLabelSizeCalculator>     LabelSize;
00215   vtkSmartPointer<vtkPointSetToLabelHierarchy> LabelHierarchy;
00216   vtkSmartPointer<vtkLabelPlacer>             LabelPlacer;
00217   vtkSmartPointer<vtkLabeledDataMapper>       LabelMapper;
00218   vtkSmartPointer<vtkActor2D>                 LabelActor;
00219   vtkSmartPointer<vtkEdgeLayout>              EdgeLayout;
00220   vtkSmartPointer<vtkGraphMapper>             GraphMapper;
00221   vtkSmartPointer<vtkActor>                   GraphActor;
00222   vtkSmartPointer<vtkGraphToPolyData>         GraphToPolyData;
00223   vtkSmartPointer<vtkEdgeCenters>             EdgeCenters;
00224   vtkSmartPointer<vtkLabeledDataMapper>       EdgeLabelMapper;
00225   vtkSmartPointer<vtkActor2D>                 EdgeLabelActor;
00226   vtkSmartPointer<vtkMaskPoints>              EdgeLabelMaskPoints;
00227   vtkSmartPointer<vtkSelectVisiblePoints>     EdgeLabelSelectVisiblePoints;
00228   vtkSmartPointer<vtkTransformPolyDataFilter> EdgeLabelTransform;
00229   vtkSmartPointer<vtkExtractSelectedGraph>    ExtractSelection;
00230   vtkSmartPointer<vtkGraphMapper>             SelectionMapper;
00231   vtkSmartPointer<vtkActor>                   SelectionActor;
00232   //ETX
00234 
00235   char* LabelArrayName;
00236   bool In3DGeoView;
00237 
00238 private:
00239   vtkGeoGraphRepresentation(const vtkGeoGraphRepresentation&);  // Not implemented.
00240   void operator=(const vtkGeoGraphRepresentation&);  // Not implemented.
00241 };
00242 
00243 #endif

Generated by  doxygen 1.7.1