VTK  9.3.20240420
vtkParallelCoordinatesActor.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
51#ifndef vtkParallelCoordinatesActor_h
52#define vtkParallelCoordinatesActor_h
53
54#include "vtkActor2D.h"
55#include "vtkRenderingAnnotationModule.h" // For export macro
56#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
57
58VTK_ABI_NAMESPACE_BEGIN
60class vtkAxisActor2D;
61class vtkDataObject;
62class vtkPolyData;
64class vtkTextMapper;
65class vtkTextProperty;
66class vtkParallelCoordinatesActorConnection;
67
68#define VTK_IV_COLUMN 0
69#define VTK_IV_ROW 1
70
71class VTKRENDERINGANNOTATION_EXPORT VTK_MARSHALAUTO vtkParallelCoordinatesActor : public vtkActor2D
72{
73public:
75 void PrintSelf(ostream& os, vtkIndent indent) override;
76
84
86
91 vtkSetClampMacro(IndependentVariables, int, VTK_IV_COLUMN, VTK_IV_ROW);
92 vtkGetMacro(IndependentVariables, int);
93 void SetIndependentVariablesToColumns() { this->SetIndependentVariables(VTK_IV_COLUMN); }
94 void SetIndependentVariablesToRows() { this->SetIndependentVariables(VTK_IV_ROW); }
96
98
101 vtkSetStringMacro(Title);
102 vtkGetStringMacro(Title);
104
106
111 vtkSetClampMacro(NumberOfLabels, int, 0, 50);
112 vtkGetMacro(NumberOfLabels, int);
114
116
119 vtkSetStringMacro(LabelFormat);
120 vtkGetStringMacro(LabelFormat);
122
124
128 vtkGetObjectMacro(TitleTextProperty, vtkTextProperty);
130
132
136 vtkGetObjectMacro(LabelTextProperty, vtkTextProperty);
138
140
147
152
158
164
169
176
177protected:
180
181private:
182 vtkParallelCoordinatesActorConnection* ConnectionHolder;
183
184 int IndependentVariables; // Use column or row
185 vtkIdType N; // The number of independent variables
186 double* Mins; // Minimum data value along this row/column
187 double* Maxs; // Maximum data value along this row/column
188 int* Xs; // Axes x-values (in viewport coordinates)
189 int YMin; // Axes y-min-value (in viewport coordinates)
190 int YMax; // Axes y-max-value (in viewport coordinates)
191 int NumberOfLabels; // Along each axis
192 char* LabelFormat;
193 char* Title;
194
195 vtkAxisActor2D** Axes;
196 vtkTextMapper* TitleMapper;
197 vtkActor2D* TitleActor;
198
199 vtkTextProperty* TitleTextProperty;
200 vtkTextProperty* LabelTextProperty;
201
202 vtkPolyData* PlotData; // The lines drawn within the axes
203 vtkPolyDataMapper2D* PlotMapper;
204 vtkActor2D* PlotActor;
205
206 vtkTimeStamp BuildTime;
207
208 int LastPosition[2];
209 int LastPosition2[2];
210
211 void Initialize();
212 int PlaceAxes(vtkViewport* viewport, const int* size);
213
215 void operator=(const vtkParallelCoordinatesActor&) = delete;
216};
217
218VTK_ABI_NAMESPACE_END
219#endif
a actor that draws 2D data
Definition vtkActor2D.h:145
Proxy object to connect input/output ports.
Create an axis with tick marks and labels.
general representation of visualization data
a simple class to control print indentation
Definition vtkIndent.h:108
create parallel coordinate display from input field
vtkDataObject * GetInput()
Remove a dataset from the list of data to append.
vtkTypeBool HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
virtual void SetLabelTextProperty(vtkTextProperty *p)
Set/Get the labels text property.
static vtkParallelCoordinatesActor * New()
Instantiate object with autorange computation; the number of labels set to 5 for the x and y axes; a ...
virtual void SetInputConnection(vtkAlgorithmOutput *)
Set the input to the parallel coordinates actor.
~vtkParallelCoordinatesActor() override
virtual void SetTitleTextProperty(vtkTextProperty *p)
Set/Get the title text property.
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
int RenderOverlay(vtkViewport *) override
Draw the parallel coordinates plot.
virtual void SetInputData(vtkDataObject *)
Set the input to the parallel coordinates actor.
void SetIndependentVariablesToRows()
Specify whether to use the rows or columns as independent variables.
void SetIndependentVariablesToColumns()
Specify whether to use the rows or columns as independent variables.
int RenderOpaqueGeometry(vtkViewport *) override
Draw the parallel coordinates plot.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int RenderTranslucentPolygonalGeometry(vtkViewport *) override
Draw the parallel coordinates plot.
draw vtkPolyData onto the image plane
concrete dataset represents vertices, lines, polygons, and triangle strips
2D text annotation
represent text properties.
record modification and/or execution time
abstract specification for Viewports
Definition vtkViewport.h:65
window superclass for vtkRenderWindow
Definition vtkWindow.h:48
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_IV_ROW
#define VTK_IV_COLUMN
int vtkIdType
Definition vtkType.h:315
#define VTK_MARSHALAUTO