FreeType version number?

How would I get, at run time, the version number of the FreeType library being used by SDL_TTF? The FT_Library_Version (https://www.freetype.org/freetype2/docs/reference/ft2-version.html) function needs the ‘source library handle’ but AFAIK that’s not exposed by SDL_TTF. Or is it?

Richard.

You might try calling FT_Init_FreeType to get your own FT_Library
instance, use it to call, then call FT_Library_Version followed by
FT_Done_FreeType.On 28.01.2017 19:55, rtrussell wrote:

How would I get, at run time, the version number of the FreeType
library being used by SDL_TTF? The FT_Library_Version
(https://www.freetype.org/freetype2/docs/reference/ft2-version.html)
function needs the ‘source library handle’ but AFAIK that’s not
exposed by SDL_TTF. Or is it?


Rainer Deyke - rainerd at eldwood.com

Rainer Deyke wrote:

You might try calling FT_Init_FreeType to get your own FT_Library instance, use it to call, then call FT_Library_Version followed by
FT_Done_FreeType.

D’oh, I really should have thought of that! It works perfectly. Thanks.

Richard.