[aseprite] 74/196: Add fixes for gcc/clang in ft::FaceFT
Tobias Hansen
thansen at moszumanska.debian.org
Wed Apr 20 18:50:03 UTC 2016
This is an automated email from the git hooks/post-receive script.
thansen pushed a commit to branch master
in repository aseprite.
commit e0135d6f579d9ef357aef740a6d88f513bf8d602
Author: David Capello <davidcapello at gmail.com>
Date: Tue Mar 15 17:45:55 2016 -0300
Add fixes for gcc/clang in ft::FaceFT
---
src/ft/face.h | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/src/ft/face.h b/src/ft/face.h
index e772ac7..5b1c58b 100644
--- a/src/ft/face.h
+++ b/src/ft/face.h
@@ -65,6 +65,7 @@ namespace ft {
template<typename Cache>
class FaceFT : public FaceBase<Cache> {
public:
+ using FaceBase<Cache>::Glyph;
using FaceBase<Cache>::m_face;
using FaceBase<Cache>::m_cache;
@@ -74,23 +75,25 @@ namespace ft {
template<typename Callback>
void forEachGlyph(const std::string& str, Callback callback) {
- bool use_kerning = (FT_HAS_KERNING(m_face) ? true: false);
+ bool use_kerning = (FT_HAS_KERNING(this->m_face) ? true: false);
FT_UInt prev_glyph = 0;
double x = 0, y = 0;
auto it = base::utf8_const_iterator(str.begin());
auto end = base::utf8_const_iterator(str.end());
for (; it != end; ++it) {
- FT_UInt glyph_index = m_cache.getGlyphIndex(m_face, *it);
+ FT_UInt glyph_index = this->m_cache.getGlyphIndex(
+ this->m_face, *it);
if (use_kerning && prev_glyph && glyph_index) {
FT_Vector kerning;
- FT_Get_Kerning(m_face, prev_glyph, glyph_index,
+ FT_Get_Kerning(this->m_face, prev_glyph, glyph_index,
FT_KERNING_DEFAULT, &kerning);
x += kerning.x / 64.0;
}
- FT_Glyph bitmapGlyph = m_cache.loadGlyph(m_face, glyph_index, m_antialias);
+ FT_Glyph bitmapGlyph = this->m_cache.loadGlyph(
+ this->m_face, glyph_index, this->m_antialias);
if (bitmapGlyph) {
Glyph glyph;
glyph.glyph_index = glyph_index;
@@ -103,7 +106,7 @@ namespace ft {
x += bitmapGlyph->advance.x / double(1 << 16);
y += bitmapGlyph->advance.y / double(1 << 16);
- m_cache.doneGlyph(bitmapGlyph);
+ this->m_cache.doneGlyph(bitmapGlyph);
}
prev_glyph = glyph_index;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git
More information about the Pkg-games-commits
mailing list