On Sat, Apr 9, 2011 at 11:31 AM, Adam Borowski <[email protected]> wrote: > On Fri, Apr 08, 2011 at 06:22:23PM +0100, Philip Taylor wrote: >> On Thu, Apr 7, 2011 at 5:35 PM, Adam Borowski <[email protected]> wrote: >> > On Thu, Apr 07, 2011 at 04:33:47PM +0100, Philip Taylor wrote: >> >> On Wed, Apr 6, 2011 at 1:24 AM, Paul Wise <[email protected]> wrote: >> >> > Preferably you would render text at run-time, since that >> >> > enables i18n. For finding font files use fontconfig (preferred) and or >> >> > a build-time parameter for finding them. >> >> >> >> My main concern is that that wouldn't provide sufficient consistency - >> >> different versions of Freetype, or the same version with different >> >> configuration (bytecode interpreter, autohinter, etc), might render >> >> the same font quite differently and break the look of the game. >> > >> > Why won't you force the settings then? If you are afraid the user's >> > configuration might be ill-fitting, specify them by hand. >> >> The important ones that I'm aware of are compile-time settings >> (TT_CONFIG_OPTION_BYTECODE_INTERPRETER/TT_CONFIG_OPTION_UNPATENTED_HINTING) > > These two are used only if you choose bytecode hinting. Just specify any > other option if you're afraid of inconsistency.
I played with this a bit, and it looks like the bytecode interpreter is necessary for some of the fonts we use. http://zaynar.co.uk/0ad-pub/fonts/fonts-default-hint.png - the normal rendering (using default font options in Cairo, which handles antialiasing etc automatically). http://zaynar.co.uk/0ad-pub/fonts/fonts-no-hint.png - FT_LOAD_NO_HINTING. http://zaynar.co.uk/0ad-pub/fonts/fonts-auto-hint.png - FT_LOAD_FORCE_AUTOHINT (or a version of Freetype with the patented code disabled). The autohinter makes everything much uglier. The main font (Pagella) doesn't use hinting - with FT_LOAD_NO_HINTING enabled it's actually the same when using the game's converted .ttf or the original .otf, so I think I can remove the converted .ttf files entirely and use the NO_HINTING flag when rendering it. But the DejaVu Sans Mono in the top-left corner looks like it really needs the original bytecode hinting, to avoid being ugly or blurry. -- Philip Taylor [email protected] -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected] Archive: http://lists.debian.org/[email protected]

