font problem???

hi
can i use ttf fonts directly (without exclusive library) in opengl. if no, how can i increase the size of a font used as
font = XLoadQueryFont(dpy, “--times-bold-r-normal–24----p-*-iso8859-1”);

i try to change the values in this string but it doesn’t work.

type ‘xlsfonts’ in the terminal and you’ll get all fonts which are installed on your system.

thanks for xlsfont command but biggest font size is 24 as far as i know. the question is how i can increase font size above 24
take it easy

Usually when I need to render fonts in some way I just use FTGL ( link ).

I know, you said you don’t want to use another library, but it’s really just a tiny one and it will save you heaps of work… allowing you to scroll those nice, shiny and anti-aliased credits around the screen in just a few minutes instead of a few hours or days :slight_smile:

Increasing the font sizes will require you to have a deeper look at the font structures of X (and surely other structures I don’t remember). What I can say, is that it’s not a simple member of struct like (size_x or size_y), but the deducted size is from several members of the structure. You can find out more well formed explanations with a good search on the internet.

Hope that helps.

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.