iMSTK
Interactive Medical Simulation Toolkit
imstkVertexLabelVisualModel.h
1 /*
2 ** This file is part of the Interactive Medical Simulation Toolkit (iMSTK)
3 ** iMSTK is distributed under the Apache License, Version 2.0.
4 ** See accompanying NOTICE for details.
5 */
6 
7 #pragma once
8 
9 #include "imstkVisualModel.h"
10 #include "imstkColor.h"
11 
12 namespace imstk
13 {
21 {
22 public:
24  {
25  setDelegateHint("VertexLabel");
26  }
27 
32  const std::string& getFormat() const { return m_format; }
33  void setFormat(const std::string& format) { m_format = format; }
35 
39  const Color& getTextColor() const { return m_textColor; }
40  void setTextColor(const Color& color) { m_textColor = color; }
42 
46  double getFontSize() const { return m_fontSize; }
47  void setFontSize(const double fontSize) { m_fontSize = fontSize; }
49 
50 protected:
51  std::string m_format = "%d";
52  Color m_textColor = Color::White;
53  double m_fontSize = 10.0;
54 };
55 } // namespace imstk
double getFontSize() const
Get/Set the font size.
const Color & getTextColor() const
Get/Set the text color.
Compound Geometry.
Color in RGB space.
Definition: imstkColor.h:24
Given a PointSet geometry it will render labels for each vertex with numberings.
static Color White
Various commonly used colors.
Definition: imstkColor.h:112
const std::string & getFormat() const
Get/Set printf style format string for every vertex d for integer.
Contains geometric, material, and render information.