RAMSES Documentation  27.0.130
Information for RAMSES users and developers
GlyphMetrics.h
Go to the documentation of this file.
1 // -------------------------------------------------------------------------
2 // Copyright (C) 2018 BMW Car IT GmbH
3 // -------------------------------------------------------------------------
4 // This Source Code Form is subject to the terms of the Mozilla Public
5 // License, v. 2.0. If a copy of the MPL was not distributed with this
6 // file, You can obtain one at https://mozilla.org/MPL/2.0/.
7 // -------------------------------------------------------------------------
8 
9 #ifndef RAMSES_GLYPHMETRICS_H
10 #define RAMSES_GLYPHMETRICS_H
11 
12 #include "ramses-text-api/Glyph.h"
13 
14 namespace ramses
15 {
25  struct GlyphMetrics
26  {
30  uint32_t width;
32  uint32_t height;
34  int32_t posX;
36  int32_t posY;
38  int32_t advance;
39  };
40 
42  using GlyphMetricsVector = std::vector<GlyphMetrics>;
43 }
44 
45 #endif
The RAMSES namespace contains all client side objects and functions used to implement RAMSES applicat...
Definition: AnimatedProperty.h:15
std::vector< GlyphMetrics > GlyphMetricsVector
Vector of GlyphMetrics elements.
Definition: GlyphMetrics.h:42
GlyphKey identifies a glyph with a specific font instance.
Definition: Glyph.h:39
GlyphMetrics describes a glyph's position and dimensions in the rasterized glyph bitmap space.
Definition: GlyphMetrics.h:26
int32_t posY
Glyph offset on y-axis.
Definition: GlyphMetrics.h:36
uint32_t height
Glyph height.
Definition: GlyphMetrics.h:32
int32_t posX
Glyph offset on x-axis.
Definition: GlyphMetrics.h:34
int32_t advance
Glyph advance (distance from origin of this glyph to where origin of next glyph should start)
Definition: GlyphMetrics.h:38
GlyphKey key
Glyph key (GlyphId + FontInstanceId)
Definition: GlyphMetrics.h:28
uint32_t width
Glyph width.
Definition: GlyphMetrics.h:30