Changed the error code reporting to use hex to match up with freetype headers
This commit is contained in:
parent
a98daccd03
commit
f6650dd3bf
@ -80,7 +80,7 @@ void FreeTypeFont::setFontResolution(unsigned int width, unsigned int height)
|
||||
|
||||
if (error)
|
||||
{
|
||||
osg::notify(osg::WARN)<<"FT_Set_Pixel_Sizes() - error "<<error<<std::endl;
|
||||
osg::notify(osg::WARN)<<"FT_Set_Pixel_Sizes() - error 0x"<<std::hex<<error<<std::dec<<std::endl;
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -110,7 +110,7 @@ osgText::Font::Glyph* FreeTypeFont::getGlyph(unsigned int charcode)
|
||||
FT_Error error = FT_Load_Char( _face, charindex, FT_LOAD_RENDER|FT_LOAD_NO_BITMAP|_flags );
|
||||
if (error)
|
||||
{
|
||||
osg::notify(osg::WARN) << "FT_Load_Char(...) error "<<error<<std::endl;
|
||||
osg::notify(osg::WARN) << "FT_Load_Char(...) error 0x"<<std::hex<<error<<std::dec<<std::endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -211,6 +211,7 @@ osg::Vec2 FreeTypeFont::getKerning(unsigned int leftcharcode,unsigned int rightc
|
||||
|
||||
if (error)
|
||||
{
|
||||
osg::notify(osg::WARN) << "FT_Get_Kerning(...) returned error code " <<std::hex<<error<<std::dec<< std::endl;
|
||||
return osg::Vec2(0.0f,0.0f);
|
||||
}
|
||||
|
||||
|
@ -27,7 +27,7 @@ FreeTypeLibrary::FreeTypeLibrary()
|
||||
FT_Error error = FT_Init_FreeType( &_ftlibrary );
|
||||
if (error)
|
||||
{
|
||||
osg::notify(osg::WARN)<<"Warning: an error occurred during FT_Init_FreeType(..) initialisation .. "<<std::endl;
|
||||
osg::notify(osg::WARN)<<"Warning: an error occurred during FT_Init_FreeType(..) initialisation, error code = "<<std::hex<<error<<std::dec<<std::endl;
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user