#36 Bug in FTSize::CharSize

open
nobody
None
5
2012-09-13
2012-09-13
Anonymous
No

In FTSize.cpp, when changing the resolution, the char size is set with the old resolution values (xResolution,yResolution) instead of the desired parameters (xRes, yRes):

45 bool FTSize::CharSize(FT_Face* face, unsigned int pointSize, unsigned int xRes, unsigned int yRes)
46 {
47 if(size != pointSize || xResolution != xRes || yResolution != yRes)
48 {
49 err = FT_Set_Char_Size(*face, 0L, pointSize * 64, xResolution, yResolution);

I resolved this by changing line 49 to:

err = FT_Set_Char_Size(*face, 0L, pointSize * 64, xRes, yRes);

Discussion