> Message: 1
> Date: Mon, 12 Mar 2018 23:25:08 +0800
> From: "duhuanpeng" <548708...@qq.com>
> To: <freetype-devel@nongnu.org>
> Subject: [ft-devel] How to port
> freetype2 to a system without file
>    system

> Hello,
 
> I have ported freetype2 to our system.
> Our system don't supports file system,
> so I write some functions to emulate
> file operations.
> fopen,  fread, etc.
> But now I maintain a "FILE" array, it
> eats a lot memory.
 
> Is there any better way to port
> freetype2? 
> Our fonts are store in flash, it
> appears like a normal array.
> like:
>   extern char font1[];
>   extern char font2[];
 
 
> (actually, I store multi font files in
> a single romfs image block.)
 
Can you not use FT_New_Memory_Face() ? That treats a block of memory as a font 
file. You should be able to pass font1, font2 directly as the 2nd argument to 
FT_New_Memory_Face() .



_______________________________________________
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel

Reply via email to