VTK
vtkPlotStacked.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPlotPoints.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 
27 #ifndef vtkPlotStacked_h
28 #define vtkPlotStacked_h
29 
30 #include "vtkChartsCoreModule.h" // For export macro
31 #include "vtkPlot.h"
32 
33 class vtkChartXY;
34 class vtkContext2D;
35 class vtkTable;
36 class vtkPoints2D;
37 class vtkStdString;
38 class vtkImageData;
39 class vtkColorSeries;
40 
41 class vtkPlotStackedPrivate;
42 
44 {
45 public:
46  vtkTypeMacro(vtkPlotStacked, vtkPlot);
47  virtual void PrintSelf(ostream &os, vtkIndent indent);
48 
50  static vtkPlotStacked *New();
51 
53 
54  virtual void SetColor(unsigned char r, unsigned char g, unsigned char b,
55  unsigned char a);
56  virtual void SetColor(double r, double g, double b);
57  virtual void GetColor(double rgb[3]);
59 
63  virtual void Update();
64 
67  virtual bool Paint(vtkContext2D *painter);
68 
70 
75  virtual bool PaintLegend(vtkContext2D *painter, const vtkRectf& rect,
76  int legendIndex);
78 
80  virtual void GetBounds(double bounds[4]);
81 
84  virtual void GetUnscaledInputBounds(double bounds[4]);
85 
87  virtual void SetInputArray(int index, const vtkStdString &name);
88 
90  void SetColorSeries(vtkColorSeries *colorSeries);
91 
93  vtkColorSeries *GetColorSeries();
94 
96  virtual vtkStringArray *GetLabels();
97 
98 //BTX
100 
104  const vtkVector2f& tolerance,
107 
109  virtual bool SelectPoints(const vtkVector2f& min, const vtkVector2f& max);
110 
111 //BTX
112 protected:
113  vtkPlotStacked();
114  ~vtkPlotStacked();
115 
117  bool UpdateTableCache(vtkTable *table);
118 
119  // Descript:
120  // For stacked plots the Extent data must be greater than (or equal to) the
121  // base data. Insure that this is true
122  void FixExtent();
123 
127  void CalculateLogSeries();
128 
132 
137 
140 
141  bool LogX, LogY;
142 
145 
146 private:
147  vtkPlotStacked(const vtkPlotStacked &); // Not implemented.
148  void operator=(const vtkPlotStacked &); // Not implemented.
149 
150  vtkPlotStackedPrivate *Private;
151 
152 //ETX
153 };
154 
155 #endif //vtkPlotStacked_h
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:46
vtkSmartPointer< vtkColorSeries > ColorSeries
virtual bool PaintLegend(vtkContext2D *painter, const vtkRectf &rect, int legendIndex)
virtual bool Paint(vtkContext2D *painter)
record modification and/or execution time
Definition: vtkTimeStamp.h:34
virtual void GetBounds(double bounds[4])
Definition: vtkPlot.h:276
vtkIdTypeArray * ExtentBadPoints
a vtkAbstractArray subclass for strings
dynamic, self-adjusting array of vtkIdType
int vtkIdType
Definition: vtkType.h:275
virtual void SetColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a)
vtkTimeStamp BuildTime
Class for drawing 2D primitives to a graphical context.
Definition: vtkContext2D.h:56
virtual bool SelectPoints(const vtkVector2f &min, const vtkVector2f &max)
a simple class to control print indentation
Definition: vtkIndent.h:38
represent and manipulate 2D points
Definition: vtkPoints2D.h:35
virtual vtkStringArray * GetLabels()
topologically and geometrically regular array of data
Definition: vtkImageData.h:44
Abstract class for 2D plots.
Definition: vtkPlot.h:51
Class for drawing an stacked polygon plot given an X, Ybase, Yextent in a vtkTable.
virtual vtkIdType GetNearestPoint(const vtkVector2f &point, const vtkVector2f &tolerance, vtkVector2f *location)
Factory class for drawing XY charts.
Definition: vtkChartXY.h:48
virtual void SetInputArray(int index, const vtkStdString &name)
A table, which contains similar-typed columns of data.
Definition: vtkTable.h:67
stores a list of colors.
virtual void GetUnscaledInputBounds(double bounds[4])
Definition: vtkPlot.h:295
virtual void PrintSelf(ostream &os, vtkIndent indent)
virtual void GetColor(double rgb[3])
vtkIdTypeArray * BaseBadPoints
static vtkObject * New()
virtual void Update()
#define max(a, b)
#define VTKCHARTSCORE_EXPORT