Tag: harfbuzz

HarfBuzz – hb_shape()会导致访问冲突

基于此示例 ,我尝试在SDL应用程序中实现字体呈现。 调用hb_shape()时 ,应用程序因访问冲突而暂停。 DLL-download-link(win32): 这里 {harfbuzz-0.9.26-win32.zip} ErrorMsg(VC2012):ConsoleApplication2.exe中0x6160B7F0(libharfbuzz-0.dll)处的未处理exception:0xC0000005:读取位置0x00000068时发生访问冲突 编辑:为简单起见,我将示例更改为控制台应用程序。 Edit2:现在静态链接,用VC ++的LIB.exe创建.lib文件。 #include #include #include #include #pragma comment(lib,”lib/x86/freetype253ST.lib”) // freetype single-thread #pragma comment (lib,”libharfbuzz-0.lib”) // linked to libharfbuzz.dll, created by LIB.exe int main() { hb_font_t* font = NULL; hb_buffer_t* buffer = NULL; FT_Library flib; FT_Face face; bool found = false; const char text[] = {“Write something….”}; […]