VTK
dox/Charts/vtkChartParallelCoordinates.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkChartParallelCoordinates.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 
00026 #ifndef __vtkChartParallelCoordinates_h
00027 #define __vtkChartParallelCoordinates_h
00028 
00029 #include "vtkChart.h"
00030 
00031 class vtkIdTypeArray;
00032 class vtkStdString;
00033 class vtkStringArray;
00034 class vtkPlotParallelCoordinates;
00035 
00036 class VTK_CHARTS_EXPORT vtkChartParallelCoordinates : public vtkChart
00037 {
00038 public:
00039   vtkTypeMacro(vtkChartParallelCoordinates, vtkChart);
00040   virtual void PrintSelf(ostream &os, vtkIndent indent);
00041 
00043   static vtkChartParallelCoordinates* New();
00044 
00048   virtual void Update();
00049 
00052   virtual bool Paint(vtkContext2D *painter);
00053 
00055   void SetColumnVisibility(const vtkStdString& name, bool visible);
00056 
00059   void SetColumnVisibilityAll(bool visible);
00060 
00062   bool GetColumnVisibility(const vtkStdString& name);
00063 
00065 
00066   vtkGetObjectMacro(VisibleColumns, vtkStringArray);
00068 
00071   virtual vtkPlot* GetPlot(vtkIdType index);
00072 
00074   virtual vtkIdType GetNumberOfPlots();
00075 
00077   virtual vtkAxis* GetAxis(int axisIndex);
00078 
00080   virtual vtkIdType GetNumberOfAxes();
00081 
00085   virtual void RecalculateBounds();
00086 
00089   virtual void SetPlot(vtkPlotParallelCoordinates *plot);
00090 
00091 //BTX
00093   virtual bool Hit(const vtkContextMouseEvent &mouse);
00094 
00096   virtual bool MouseEnterEvent(const vtkContextMouseEvent &mouse);
00097 
00099   virtual bool MouseMoveEvent(const vtkContextMouseEvent &mouse);
00100 
00102   virtual bool MouseLeaveEvent(const vtkContextMouseEvent &mouse);
00103 
00105   virtual bool MouseButtonPressEvent(const vtkContextMouseEvent &mouse);
00106 
00108   virtual bool MouseButtonReleaseEvent(const vtkContextMouseEvent &mouse);
00109 
00111 
00113   virtual bool MouseWheelEvent(const vtkContextMouseEvent &mouse, int delta);
00114 //ETX
00116 
00117 //BTX
00118 protected:
00119   vtkChartParallelCoordinates();
00120   ~vtkChartParallelCoordinates();
00121 
00123 
00124   class Private;
00125   Private *Storage;
00127 
00128   bool GeometryValid;
00129 
00131   vtkIdTypeArray *Selection;
00132 
00134   vtkStringArray *VisibleColumns;
00135 
00137   vtkTimeStamp BuildTime;
00138 
00139   void ResetSelection();
00140   void UpdateGeometry();
00141   void CalculatePlotTransform();
00142   void SwapAxes(int a1, int a2);
00143 
00144 private:
00145   vtkChartParallelCoordinates(const vtkChartParallelCoordinates &); // Not implemented.
00146   void operator=(const vtkChartParallelCoordinates &);   // Not implemented.
00147 //ETX
00148 };
00149 
00150 #endif //__vtkChartParallelCoordinates_h