diff options
| author | Geenz <geenz@geenzo.com> | 2013-05-13 22:22:51 -0400 |
|---|---|---|
| committer | Geenz <geenz@geenzo.com> | 2013-05-13 22:22:51 -0400 |
| commit | 3779e51bfc2010877960d11b463c7316514bf991 (patch) | |
| tree | ab528a6e7f78f136f9d0f0f7e939264897a44ae1 /indra/llrender/llfontgl.cpp | |
| parent | b27899ee0e035ebd4072a5e6162678f2afe81053 (diff) | |
| parent | 4dd245055f3417d8f8fb611a198ed5671dbce292 (diff) | |
Merged with https://bitbucket.org/lindenlab/viewer-beta
Diffstat (limited to 'indra/llrender/llfontgl.cpp')
| -rwxr-xr-x[-rw-r--r--] | indra/llrender/llfontgl.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/llrender/llfontgl.cpp b/indra/llrender/llfontgl.cpp index 647512eb2e..c4f36cabd0 100644..100755 --- a/indra/llrender/llfontgl.cpp +++ b/indra/llrender/llfontgl.cpp @@ -541,7 +541,6 @@ S32 LLFontGL::maxDrawableChars(const llwchar* wchars, F32 max_pixels, S32 max_ch BOOL clip = FALSE; F32 cur_x = 0; - F32 drawn_x = 0; S32 start_of_last_word = 0; BOOL in_word = FALSE; @@ -599,6 +598,11 @@ S32 LLFontGL::maxDrawableChars(const llwchar* wchars, F32 max_pixels, S32 max_ch if(!fgi) { fgi = mFontFreetype->getGlyphInfo(wch); + + if (NULL == fgi) + { + return 0; + } } // account for glyphs that run beyond the starting point for the next glyphs @@ -624,7 +628,6 @@ S32 LLFontGL::maxDrawableChars(const llwchar* wchars, F32 max_pixels, S32 max_ch // Round after kerning. cur_x = (F32)llround(cur_x); - drawn_x = cur_x; } if( clip ) |
