17 #ifndef vtkContextDevice2D_h
18 #define vtkContextDevice2D_h
22 #include "vtkRenderingContext2DModule.h"
28 VTK_ABI_NAMESPACE_BEGIN
58 virtual void DrawPoly(
59 float*
points,
int n,
unsigned char* colors =
nullptr,
int nc_comps = 0) = 0;
67 virtual void DrawLines(
float* f,
int n,
unsigned char* colors =
nullptr,
int nc_comps = 0) = 0;
73 virtual void DrawPoints(
74 float*
points,
int n,
unsigned char* colors =
nullptr,
int nc_comps = 0) = 0;
76 std::uintptr_t vtkNotUsed(cacheIdentifier));
89 unsigned char* colors =
nullptr,
int nc_comps = 0) = 0;
108 virtual void DrawMarkers(
int shape,
bool highlight,
float*
points,
int n,
109 unsigned char* colors =
nullptr,
int nc_comps = 0);
110 virtual void DrawMarkers(
int shape,
bool highlight,
vtkDataArray* positions,
127 virtual void DrawPolygon(
float* p,
int n) { this->DrawColoredPolygon(p, n); }
128 virtual void DrawColoredPolygon(
129 float*
points,
int numPoints,
unsigned char* colors =
nullptr,
int nc_comps = 0);
143 virtual void DrawEllipseWedge(
float x,
float y,
float outRx,
float outRy,
float inRx,
float inRy,
152 virtual void DrawEllipticArc(
153 float x,
float y,
float rX,
float rY,
float startAngle,
float stopAngle) = 0;
167 virtual void ComputeStringBounds(
const vtkStdString&
string,
float bounds[4]) = 0;
174 virtual void ComputeJustifiedStringBounds(
const char*
string,
float bounds[4]) = 0;
185 virtual bool MathTextIsSupported();
219 virtual void DrawPolyData(
227 virtual void ApplyPen(
vtkPen* pen);
235 vtkGetObjectMacro(Pen,
vtkPen);
243 virtual void ApplyBrush(
vtkBrush* brush);
270 virtual void SetColor4(
unsigned char color[4]) = 0;
287 virtual void SetPointSize(
float size) = 0;
292 virtual void SetLineWidth(
float width) = 0;
297 virtual void SetLineType(
int type) = 0;
302 virtual int GetWidth() {
return this->Geometry[0]; }
327 virtual void PushMatrix() = 0;
332 virtual void PopMatrix() = 0;
338 virtual void SetClipping(
int* x) = 0;
349 virtual void EnableClipping(
bool enable) = 0;
365 virtual bool GetBufferIdMode()
const;
383 virtual void BufferIdModeEnd();
389 vtkGetMacro(ViewportRect,
vtkRecti);
396 virtual void ReleaseCache(std::uintptr_t vtkNotUsed(cacheIdentifier)) {}
428 VTK_ABI_NAMESPACE_END
429 #endif // vtkContextDevice2D_h
Wrapper around std::string to keep symbols short.
virtual void SetViewportRect(const vtkRecti &rect)
abstract base class for most VTK objects
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
abstract specification for Viewports
virtual void DrawPolygon(float *p, int n)
Draw a polygon using the specified number of points.
virtual int GetHeight()
Get the width of the device in pixels.
concrete dataset represents vertices, lines, polygons, and triangle strips
virtual void Begin(vtkViewport *)
Begin drawing, pass in the viewport to set up the view.
virtual void DisableClipping()
Disable clipping of the display.
vtkVector2i ViewportSize
Store the size of the total viewport.
window superclass for vtkRenderWindow
virtual void ReleaseCache(std::uintptr_t vtkNotUsed(cacheIdentifier))
Concrete graphics implementations maintain a cache of heavy-weight buffer objects to achieve higher i...
provides a brush that fills shapes drawn by vtkContext2D.
a simple class to control print indentation
represent and manipulate 2D points
topologically and geometrically regular array of data
abstract superclass for arrays of numeric data
vtkAbstractContextBufferId * BufferId
Some derived classes for the different vectors commonly used.
virtual void DrawQuadStrip(float *, int)
Draw a quad using the specified number of points.
Abstract class for drawing 2D primitives.
virtual int GetWidth()
Get the width of the device in pixels.
provides a pen that draws the outlines of shapes drawn by vtkContext2D.
represent text properties.
dynamic, self-adjusting array of unsigned char
virtual void SetViewportSize(const vtkVector2i &size)
virtual void DrawQuad(float *, int)
Draw a quad using the specified number of points.
2D array of ids, used for picking.
virtual void End()
End drawing, clean up the view.
vtkRecti ViewportRect
Store our origin and size in the total viewport.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
represent and manipulate 3x3 transformation matrices
vtkTextProperty * TextProp