freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] FT_Init_FreeType allocating memory before I get a chance


From: Werner LEMBERG
Subject: Re: [ft-devel] FT_Init_FreeType allocating memory before I get a chance to set the allocators.
Date: Sun, 21 Jun 2009 21:58:30 +0200 (CEST)

> both FT_New_Memory, and FT_New_Library (functions called within
> FT_Init_FreeType) are allocating memory, before I have a chance of
> setting the function pointers in FT_Memory..  To get around that I
> added an extra argument to the FT_Init_FreeType, which allows me to
> provide an FT_Memory structure, before any other freetype code is
> running.

The `canonical' way is to replace ftsystem.c with something more
appropriate for your target platform.  For example, you can copy the
whole file, only replacing `FT_New_Memory' to fit your needs.  I don't
see an immediate need to add new API functions -- you have to convince
me that the just outlined method doesn't work :-)


    Werner




reply via email to

[Prev in Thread] Current Thread [Next in Thread]