mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-01-18 23:52:02 +00:00
Fix the LSB alignment and switch to the internal TTF implementation
This commit is contained in:
parent
ccdbc8450a
commit
ba274757be
2 changed files with 2 additions and 2 deletions
|
@ -14,7 +14,7 @@
|
|||
#include <stdexcept>
|
||||
#include <cstring>
|
||||
|
||||
// #define USE_INTERNAL_TTF
|
||||
#define USE_INTERNAL_TTF
|
||||
|
||||
class CanvasTexture
|
||||
{
|
||||
|
|
|
@ -276,7 +276,7 @@ TrueTypeGlyph TrueTypeFont::LoadGlyph(uint32_t glyphIndex, double height) const
|
|||
|
||||
// TBD: gridfit or not?
|
||||
glyph.advanceWidth = (int)std::round(advanceWidth * scale * scaleX);
|
||||
glyph.leftSideBearing = (int)std::round(lsb * scale * scaleX + bboxMin.x);
|
||||
glyph.leftSideBearing = (int)std::round(bboxMin.x);
|
||||
glyph.yOffset = (int)std::round(bboxMin.y);
|
||||
|
||||
return glyph;
|
||||
|
|
Loading…
Reference in a new issue