On 13-10-01 01:06 PM, Eduardo Castineyra wrote: >>> 4) What is get_ft_library for? Should I be calling it instead of >>> FT_Init_FreeType? >> get_ft_library() is not public, so I guess you don’t need to (can’t >> even?) use it. > > Our main concern is I don't know what would happen if, for instance, we call > the shaper from two different threads, given that ft_library is static.
The static ft_library is not used by hb_ft_font_create(). As long as you use different FT_Library's from different threads, you are safe. > /* Thread-safe, lock-free, FT_Library */ > static FT_Library ft_library; > > Despite the "Thread-safe" comment, we have experienced a lot of problems when > two threads are using the same FT_library. So I don't understand what the > "Thread-safe" claim is based on. The "thread-safe" claim is in the initialization of the ft_library variable itself, not about the implementation of FT_Library functions. > Also, do most users rely on hb-ft? Or they usually make their own font > parsers? No one usually make their own font parsers. But most serious users don't use hb-ft and hook up hb to their graphics library (cairo, win32, webkit, skia, whatever). Most small users use hb-ft. -- behdad http://behdad.org/ _______________________________________________ HarfBuzz mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/harfbuzz
