93 void set_text(std::string text);
101 void set_pen(
float pen_x,
float pen_y);
114 void set_center(std::optional<glm::vec2> center);
120 void set_color(glm::vec3 color);
126 void set_thickness(
float thickness);
135 [[nodiscard]]
const std::vector<Portal::Text::GlyphOutline>&
outlines()
const
146 [[nodiscard]]
const std::vector<glm::vec2>&
pen_offsets()
const {
return m_pen_offsets; }
158 void set_pen_offsets(std::vector<glm::vec2> offsets);
166 void rebuild_outlines();
171 void compute_frame()
override;
175 return Portal::Graphics::PrimitiveTopology::LINE_LIST;
180 uint32_t m_pixel_size {};
184 float m_tolerance { 0.5F };
186 float m_total_advance {};
187 float m_line_height {};
189 glm::vec3 m_color { 1.F, 1.F, 1.F };
190 float m_thickness { 1.F };
197 void write_vertices();
Owns a single FT_Face loaded from a file path.