Wintermute Engine Forum

Wintermute Engine => Technical forum => Topic started by: noxis on October 22, 2006, 07:32:27 AM

Title: Anti-aliased TTF Font Issue
Post by: noxis on October 22, 2006, 07:32:27 AM
I have been testing the use of true type fonts within WME, and I can't seem to make the text anti-aliased, I have added the shadow around the text, but it just doesn't seem to be anti-aliasing.

Here is the code that I used for the .fon file

TTFONT
{
  SIZE = 8 
  FACE = "Verdana"
  FILENAME = "fonts\verdana.ttf"

  BOLD = TRUE
  ITALIC = FALSE
  UNDERLINE = FALSE
  STRIKE = FALSE

  CHARSET = 1

  COLOR { 255, 0, 0 }
  ALPHA = 255
 
  LAYER
  {
    OFFSET_X = 1
    OFFSET_Y = 1
    COLOR { 0, 0, 0 }
    ALPHA = 255
  }

  LAYER
  {
    OFFSET_X = -1
    OFFSET_Y = -1
    COLOR { 0, 0, 0 }
    ALPHA = 255
  }

  LAYER
  {
    OFFSET_X = -1
    OFFSET_Y = 1
    COLOR { 0, 0, 0 }
    ALPHA = 255
  }

  LAYER
  {
    OFFSET_X = 1
    OFFSET_Y = -1
    COLOR { 0, 0, 0 }
    ALPHA = 255
  }


  LAYER
  {
    OFFSET_X = 0
    OFFSET_Y = 0
    COLOR { 255, 0, 0 }
    ALPHA = 255
  }
}
Title: Re: Anti-aliased TTF Font Issue
Post by: Mnemonic on October 22, 2006, 08:40:39 AM
I suppose Windows doesn't antialias fonts of certain sizes. You should see antialiased edges if you make the font bigger.
Title: Re: Anti-aliased TTF Font Issue
Post by: noxis on October 22, 2006, 09:17:26 AM
Will do, I'll try and do that and see if it works, I originally tried Verdana at size 12 and it still seemed that edges were jagged, but I'll try even larger.