VTK  9.2.20230603
vtkQtLabelRenderStrategy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkQtLabelRenderStrategy.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 =========================================================================*/
28 #ifndef vtkQtLabelRenderStrategy_h
29 #define vtkQtLabelRenderStrategy_h
30 
31 #include "vtkLabelRenderStrategy.h"
32 #include "vtkRenderingQtModule.h" // For export macro
33 
34 VTK_ABI_NAMESPACE_BEGIN
37 class vtkPlaneSource;
40 class vtkTexture;
41 class vtkTexturedActor2D;
43 
44 class VTKRENDERINGQT_EXPORT vtkQtLabelRenderStrategy : public vtkLabelRenderStrategy
45 {
46 public:
47  void PrintSelf(ostream& os, vtkIndent indent) override;
50 
54  void ComputeLabelBounds(vtkTextProperty* tprop, vtkStdString label, double bds[4]) override;
55 
57 
61  void RenderLabel(int x[2], vtkTextProperty* tprop, vtkStdString label) override;
62  void RenderLabel(int x[2], vtkTextProperty* tprop, vtkStdString label, int maxWidth) override;
64 
68  void StartFrame() override;
69 
73  void EndFrame() override;
74 
80  void ReleaseGraphicsResources(vtkWindow* window) override;
81 
82 protected:
85 
86  class Internals;
88 
95  bool AntialiasText; // Should the text be antialiased, inherited from render window.
96 
97 private:
99  void operator=(const vtkQtLabelRenderStrategy&) = delete;
100 };
101 
102 VTK_ABI_NAMESPACE_END
103 #endif
a simple class to control print indentation
Definition: vtkIndent.h:120
Superclass for label rendering implementations.
This filter takes an input dataset, an array to process (which must be a string array),...
draw text labels at dataset points
create an array of quadrilaterals located in a plane
draw vtkPolyData onto the image plane
Create image data from a QImage.
void EndFrame() override
End a rendering frame.
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkStdString label) override
Render a label at a location in world coordinates.
void ReleaseGraphicsResources(vtkWindow *window) override
Release any graphics resources that are being consumed by this strategy.
vtkTextureMapToPlane * TextureMapToPlane
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkStdString label, int maxWidth) override
Render a label at a location in world coordinates.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkQtLabelRenderStrategy() override
vtkQImageToImageSource * QImageToImage
void StartFrame() override
Start a rendering frame.
void ComputeLabelBounds(vtkTextProperty *tprop, vtkStdString label, double bds[4]) override
Compute the bounds of a label.
static vtkQtLabelRenderStrategy * New()
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:110
represent text properties.
generate texture coordinates by mapping points to plane
handles properties associated with a texture map
Definition: vtkTexture.h:179
actor that draws 2D data with texture support
window superclass for vtkRenderWindow
Definition: vtkWindow.h:40