@@ -360,11 +360,6 @@ void RE_GlyphChar( fontInfo_t *font, int ch, glyphInfo_t *glyph )
360360 *glyph = font->glyphBlock [ ch / 256 ][ ch % 256 ];
361361}
362362
363- void RE_Glyph ( fontInfo_t *font, const char *str, glyphInfo_t *glyph )
364- {
365- RE_GlyphChar ( font, Q_UTF8_CodePoint ( str ), glyph );
366- }
367-
368363static void RE_StoreImage ( fontInfo_t *font, int chunk, int page, int from, int to, const unsigned char *bitmap, int yEnd )
369364{
370365 int scaledSize = FONT_SIZE * FONT_SIZE;
@@ -642,7 +637,6 @@ fontInfo_t* RE_RegisterFont( const char *fontName, int pointSize )
642637 if ( len > 0x5004 && len <= 0x5004 + MAX_QPATH ) // 256 glyphs, scale info, and the bitmap name
643638 {
644639 glyphInfo_t *glyphs;
645- int height = 0 ;
646640
647641 ri.FS_ReadFile ( fileName, &faceData );
648642 fdOffset = 0 ;
@@ -652,13 +646,7 @@ fontInfo_t* RE_RegisterFont( const char *fontName, int pointSize )
652646
653647 for ( i = 0 ; i < GLYPHS_PER_FONT; i++ )
654648 {
655- glyphs[ i ].height = readInt ();
656-
657- if ( glyphs[ i ].height > height )
658- {
659- height = glyphs[ i ].height ;
660- }
661-
649+ /* height */ readInt ();
662650 glyphs[ i ].top = readInt ();
663651 glyphs[ i ].bottom = readInt ();
664652 glyphs[ i ].pitch = readInt ();
@@ -675,8 +663,7 @@ fontInfo_t* RE_RegisterFont( const char *fontName, int pointSize )
675663 }
676664
677665 font->pointSize = pointSize;
678- font->height = height;
679- font->glyphScale = readFloat ();
666+ /* glyphScale */ readFloat ();
680667 Q_strncpyz ( font->name , registeredName, sizeof ( font->name ) );
681668
682669 ri.FS_FreeFile ( faceData );
@@ -728,8 +715,6 @@ fontInfo_t* RE_RegisterFont( const char *fontName, int pointSize )
728715 font->face = face;
729716 font->faceData = faceData;
730717 font->pointSize = pointSize;
731- font->glyphScale = 64 .0f / pointSize;
732- font->height = ceil ( ( face->height / 64.0 ) * ( face->size ->metrics .y_scale / 65536.0 ) * font->glyphScale );
733718
734719 RE_RenderChunk ( font, 0 );
735720
0 commit comments