VTK  9.3.0
vtkPolyDataItem.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
15#ifndef vtkPolyDataItem_h
16#define vtkPolyDataItem_h
17
18#include "vtkContextItem.h"
19#include "vtkRenderingContext2DModule.h" // For export macro
20
21VTK_ABI_NAMESPACE_BEGIN
22class vtkPolyData;
24
25class VTKRENDERINGCONTEXT2D_EXPORT vtkPolyDataItem : public vtkContextItem
26{
27public:
29 void PrintSelf(ostream& os, vtkIndent indent) override;
30
32
36 bool Paint(vtkContext2D* painter) override;
37
41 void SetPolyData(vtkPolyData* polyData);
42
48
52 vtkGetObjectMacro(PolyData, vtkPolyData);
53
57 vtkSetVector2Macro(Position, float);
58
62 vtkSetMacro(ScalarMode, int);
63
64protected:
66 ~vtkPolyDataItem() override;
67
68 class DrawHintsHelper;
69 DrawHintsHelper* HintHelper;
70
71 float Position[2];
72
74
76
78
79private:
80 vtkPolyDataItem(const vtkPolyDataItem&) = delete;
81 void operator=(const vtkPolyDataItem&) = delete;
82};
83
84VTK_ABI_NAMESPACE_END
85#endif
Class for drawing 2D primitives to a graphical context.
base class for items that are part of a vtkContextScene.
a simple class to control print indentation
Definition vtkIndent.h:29
Filter that translate a vtkPolyData 2D mesh into vtkContextItems.
void SetPolyData(vtkPolyData *polyData)
Set the PolyData of the item.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkUnsignedCharArray * MappedColors
bool Paint(vtkContext2D *painter) override
Paint event for the item.
~vtkPolyDataItem() override
DrawHintsHelper * HintHelper
static vtkPolyDataItem * New()
void SetMappedColors(vtkUnsignedCharArray *colors)
Set mapped colors.
vtkPolyData * PolyData
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition vtkPolyData.h:80
dynamic, self-adjusting array of unsigned char