// Font generated by stb_font_inl_generator.c (4/1 bpp) // // Following instructions show how to use the only included font, whatever it is, in // a generic way so you can replace it with any other font by changing the include. // To use multiple fonts, replace STB_SOMEFONT_* below with STB_FONT_arial_bold_7_latin1_*, // and separately install each font. Note that the CREATE function call has a // totally different name; it's just 'stb_font_arial_bold_7_latin1'. // /* // Example usage: static stb_fontchar fontdata[STB_SOMEFONT_NUM_CHARS]; static void init(void) { // optionally replace both STB_SOMEFONT_BITMAP_HEIGHT with STB_SOMEFONT_BITMAP_HEIGHT_POW2 static unsigned char fontpixels[STB_SOMEFONT_BITMAP_HEIGHT][STB_SOMEFONT_BITMAP_WIDTH]; STB_SOMEFONT_CREATE(fontdata, fontpixels, STB_SOMEFONT_BITMAP_HEIGHT); ... create texture ... // for best results rendering 1:1 pixels texels, use nearest-neighbor sampling // if allowed to scale up, use bilerp } // This function positions characters on integer coordinates, and assumes 1:1 texels to pixels // Appropriate if nearest-neighbor sampling is used static void draw_string_integer(int x, int y, char *str) // draw with top-left point x,y { ... use texture ... ... turn on alpha blending and gamma-correct alpha blending ... glBegin(GL_QUADS); while (*str) { int char_codepoint = *str++; stb_fontchar *cd = &fontdata[char_codepoint - STB_SOMEFONT_FIRST_CHAR]; glTexCoord2f(cd->s0, cd->t0); glVertex2i(x + cd->x0, y + cd->y0); glTexCoord2f(cd->s1, cd->t0); glVertex2i(x + cd->x1, y + cd->y0); glTexCoord2f(cd->s1, cd->t1); glVertex2i(x + cd->x1, y + cd->y1); glTexCoord2f(cd->s0, cd->t1); glVertex2i(x + cd->x0, y + cd->y1); // if bilerping, in D3D9 you'll need a half-pixel offset here for 1:1 to behave correct x += cd->advance_int; } glEnd(); } // This function positions characters on float coordinates, and doesn't require 1:1 texels to pixels // Appropriate if bilinear filtering is used static void draw_string_float(float x, float y, char *str) // draw with top-left point x,y { ... use texture ... ... turn on alpha blending and gamma-correct alpha blending ... glBegin(GL_QUADS); while (*str) { int char_codepoint = *str++; stb_fontchar *cd = &fontdata[char_codepoint - STB_SOMEFONT_FIRST_CHAR]; glTexCoord2f(cd->s0f, cd->t0f); glVertex2f(x + cd->x0f, y + cd->y0f); glTexCoord2f(cd->s1f, cd->t0f); glVertex2f(x + cd->x1f, y + cd->y0f); glTexCoord2f(cd->s1f, cd->t1f); glVertex2f(x + cd->x1f, y + cd->y1f); glTexCoord2f(cd->s0f, cd->t1f); glVertex2f(x + cd->x0f, y + cd->y1f); // if bilerping, in D3D9 you'll need a half-pixel offset here for 1:1 to behave correct x += cd->advance; } glEnd(); } */ #ifndef STB_FONTCHAR__TYPEDEF #define STB_FONTCHAR__TYPEDEF typedef struct { // coordinates if using integer positioning float s0,t0,s1,t1; signed short x0,y0,x1,y1; int advance_int; // coordinates if using floating positioning float s0f,t0f,s1f,t1f; float x0f,y0f,x1f,y1f; float advance; } stb_fontchar; #endif #define STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH 256 #define STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT 30 #define STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT_POW2 32 #define STB_FONT_arial_bold_7_latin1_FIRST_CHAR 32 #define STB_FONT_arial_bold_7_latin1_NUM_CHARS 224 #define STB_FONT_arial_bold_7_latin1_LINE_SPACING 5 static unsigned int stb__arial_bold_7_latin1_pixels[]={ 0x4c04c531,0x44282141,0x4c1ba882,0x4c2441c3,0x260c4c0a,0x41b88d41, 0xb84c2a09,0x40b98380,0x8ddcc09a,0x0220e609,0x21419831,0x0dc142a8, 0x4c417066,0x310a0542,0x2a19b885,0x85510d41,0x20d41882,0x2604c0a9, 0x888ccaa2,0x41570989,0x44730899,0x20ca86a2,0x2e2c99c8,0x397032a2, 0x0e5c0cb8,0xba545113,0x2588542b,0x44cc750a,0xa9967662,0xa86ff438, 0x65471530,0x516e0544,0x82a09888,0x0d4146bb,0x542b8826,0xad986a21, 0x8350aa2f,0x4426221a,0x21531099,0x20dc28a9,0x9854aa2a,0xb970d8c9, 0x8dc36323,0x6d5225da,0x799370da,0xdada8dc9,0x2a1b5b50,0xb5b50dad, 0x29134ae1,0x498dc4db,0x2572442a,0x34ae0726,0x570a93f2,0x32a08c9a, 0x2e5bb51d,0x54ae6e5b,0xbb96ae6b,0x5bb96ee5,0x1dca9aea,0x5e4e4d75, 0x32a3b953,0x2e3b951d,0x257372b9,0x96d72b9b,0x370dc6ba,0x5cb9306e, 0x64b933aa,0x39581790,0x55c5dcea,0x3a8e46e3,0xa8e4ea39,0x95cea393, 0x065e5226,0x20a8b637,0x2b9a570e,0x4d8695c7,0x5d99a570,0x54e4ea72, 0x26e199b3,0x4dcd952b,0x36199b2c,0x2199b0cc,0x4ea726ca,0x2e76e6ca, 0x27275392,0x2e75393a,0x257372b9,0xb7b72b9b,0xb86e3654,0x174aa371, 0x71741bb7,0x73897a63,0x6e55cae5,0xb95c6e0b,0x95cae572,0x5cae572b, 0x8d9244d2,0x8854911b,0xbb134ae4,0x4d8695c9,0x54695c2a,0x6cc37662, 0x6d4b950d,0x2e1d972d,0x54b952da,0xcb972a5c,0x2e1bb30e,0x49bb70ec, 0x1bb30dd9,0x6ed43766,0x36a5bb52,0x5cdb372d,0x1b86e0ec,0x71a66237, 0x51c46983,0x49bb10a8,0x2e3b9ac8,0x6c49bb13,0x8937624d,0x937a64dd, 0x6c4d754b,0x5c2a1d11,0x91137a63,0x4d84de98,0x226f4c2a,0x00000001, 0x00000000,0x00000000,0x403ccdc0,0x20dc6e1b,0x02604409,0x22001806, 0x00001881,0x1304c000,0x304260c4,0x20004400,0x00000208,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x350e0000,0x261c42a8, 0x206a0cc1,0x55409a80,0x98381cc0,0x0c660881,0x0c620c62,0x81750288, 0x4439109a,0x420a8832,0x5510aa08,0x41980ba8,0x983302a2,0x5d40260b, 0x37302e20,0x2044c1a8,0x211306e2,0xb8822308,0x11114260,0x664c6a28, 0x2e659932,0x5c59732b,0x09306a20,0x75073075,0x50710730,0x9cc3a443, 0x1a839cc3,0x51aaba87,0xc8f2e1bb,0x92d6448b,0x50e74371,0x06d6d459, 0xba9c4573,0x9d98eea5,0x535026e5,0xd996aa35,0x5cb570d9,0x3abb42dc, 0xc8ccb72a,0x1d5b30d8,0x3b9734ae,0x26ee3724,0x2ee33771,0x2a337719, 0xd91aea6b,0x7640ec81,0x3b207640,0x87207640,0x55408aba,0x20455408, 0x5e543aca,0x261b9728,0x826ae62e,0x39390eac,0x4bb717a2,0x372e751c, 0x86c646a2,0x2e0724cc,0x222ea1dc,0xa89c92e2,0x5ce4bd31,0x320ddb42, 0x326532b9,0x2b9d4725,0x171d55cd,0xb9ef5c6e,0x27bd73de,0x4d953deb, 0x21d746ca,0x21d743ae,0x21d743ae,0x5c0ee3ae,0xa84aa859,0xbb86d859, 0x23dbb28b,0x65e40db9,0x76e4d510,0xc84db391,0x464ae570,0x259c922b, 0x8e570c9b,0x2eae3a9b,0x5dc36128,0x21b393c8,0x5da52dd9,0x29976cc3, 0x3b9ab8ba,0x0ddb9a57,0x42b8dca6,0x0ae15c2b,0x3b2e1d97,0x7d4ddf50, 0xa9bbea6e,0x9bbea6ef,0x372a6efa,0x54a2dca1,0x3a85b944,0x2723ab98, 0x73513aa2,0x1c8f6a19,0xda876ed4,0xd9937624,0x24d9922d,0x937625d9, 0x2ae60ddb,0xdbb136a3,0xdba976a3,0x37769b71,0xd33a9540,0xd32fec88, 0x7380dc9b,0x75d37ae3,0x2e9bd74d,0x86c004de,0x6c721b1c,0x8e436390, 0x6436390d,0x20410221,0x20208110,0x8180003a,0x00010020,0x00000000, 0x80000000,0x21100019,0x01801308,0x00000044,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x20ab8000, 0x28106a20,0x98222213,0x1404c098,0x81773013,0x3188cc09,0x25510261, 0x23501319,0x5c4060b8,0x850222bb,0x554c2609,0x1a8a6530,0x42e13026, 0x1c2a1bb9,0x19945115,0x22a85145,0x30a21bba,0x0ddcc377,0x2ee61773, 0x23314260,0x30984442,0x2e222577,0x55c792ab,0x4d5706c5,0x7d732b9b, 0x9721de4b,0x2aee1cdb,0x74c772a6,0x4dc6e132,0x573a8cc1,0x5c971a83, 0x19dcc85b,0x75098995,0x26a9854d,0x8a62bb6b,0x11e55c2b,0x1d6545d3, 0x6c6c59b3,0x9a27249d,0x17932baa,0xd3770764,0x57734ddc,0x2b9aaeeb, 0x32a5b5cd,0x26ee372e,0x3bd33971,0x764d1132,0x2e1df70d,0x99d952b9, 0x5b997261,0x8dd966ee,0x2275390d,0x5c6e372a,0x72a8dc4c,0x4c8dc3b9, 0x9d883336,0xb81193de,0x50dcd951,0xbaed65c5,0xeb8571dc,0x86d84b86, 0x5eed5c6c,0x360eb262,0x475d0ae0,0x37ae5cdb,0x95d732e4,0x5cfbd70d, 0x4eef25bd,0x2e7bd71b,0x8aeb3151,0x3b2240d8,0x2e5bb51d,0x972e5ddc, 0x9bb71fde,0xbb30e964,0x371b9541,0x26370fae,0x8dc55371,0xd7172a2a, 0x5c5d989d,0x86e1d971,0xbadf55c5,0xcb8572a9,0x1d416a3b,0xbe983ba2, 0x206f40eb,0xdf515c2a,0x571e5dcd,0xb872e1d1,0x9a2ae1d2,0x376e6d9b, 0x370ae370,0x92d4fb66,0x47bb21dd,0x800001d8,0xd702ee58,0x2e55007b, 0x8366e371,0x2a6e551b,0x401546e2,0xb80bbd36,0x5c586e01,0x553759f9, 0xe95cf7ae,0x3a87bdd0,0x27e2cd64,0x2a85c879,0x4721b15c,0x37ae1d2b, 0x7bd70ae5,0x266e695c,0xdeb8dc07,0x00000004,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x3111bb98,0x1998544c,0x00c630c6,0x2e0c8223,0x313110cb, 0x1b88015c,0xa8222211,0x26370540,0x8c453099,0x54266639,0x998a2530, 0x2aa0c331,0x5edc550a,0x26152881,0x85554133,0x0000001b,0x00000000, 0xbb800000,0x223b9709,0xda976a4e,0x4527e765,0x5c36324c,0x64b590cc, 0x3aa0ebec,0x0edc7751,0x0ef54033,0xbba84c9b,0x54e61791,0x864b6ea5, 0x2b217749,0x9836e914,0x44411099,0x4422b90a,0x33304130,0x00000001, 0x00000000,0xdb800000,0x2a55370c,0x5f0b10ec,0xcb8ee6d4,0x1b897263, 0x64e43f72,0x417b50c9,0x0037265d,0xcaa85644,0x751eec80,0x25507728, 0x210c4f20,0x00066750,0x00000000,0x00000000,0x00000000,0xb82ae000, 0xbdd042a9,0x8f887564,0x507a1dc7,0x32720888,0x555030c8,0x444aa110, 0x00000208,0x00000000,0x00000000,0x00000000,0x00000000,0x57000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000, }; static signed short stb__arial_bold_7_latin1_x[224]={ 0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,-1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,0,0,0,0,0,0,0, -1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,-1,0,0,0,0,-1,-1,0,0,0,0,0,0,-1,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,-1,0,0,0,0,0,-1,0,-1,-1,-1,0,0,0,0,0,0,0,0,0,0,0,0,-1,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,-1,0,-1,-1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, }; static signed short stb__arial_bold_7_latin1_y[224]={ 5,0,0,0,0,0,0,0,0,0,0,1,4,2, 4,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5,0,1,0,1,0,1,0,1,0,0, 0,0,0,1,1,1,1,1,1,1,0,1,1,1,1,1,1,0,0,0,2,1,1,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,5,1,0,0,1,0, 0,0,0,0,0,1,1,2,0,-1,0,0,0,0,0,1,0,2,5,0,0,1,0,0,0,1,-1,-1,-1,-1, -1,-1,0,0,-1,-1,-1,-1,-1,-1,-1,-1,0,-1,-1,-1,-1,-1,-1,1,0,-1,-1,-1,-1,-1,0,0,0,0, 0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0, }; static unsigned short stb__arial_bold_7_latin1_w[224]={ 0,2,3,4,4,6,5,2,2,2,3,4,2,2, 2,3,4,3,4,4,4,4,4,4,4,4,2,2,4,4,4,4,7,5,5,5,5,4,4,5,5,2,3,5, 4,5,5,5,4,5,5,4,4,5,6,6,5,6,4,2,3,2,4,5,2,4,4,4,4,4,3,4,4,2, 3,4,2,6,4,4,4,4,3,4,3,4,4,5,4,4,4,3,2,3,4,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,2,4,4,4,4, 2,4,3,6,3,4,4,2,6,5,3,4,2,2,2,4,5,2,2,2,3,4,6,6,6,4,5,5,5,5, 5,5,7,5,4,4,4,4,3,2,3,3,6,5,5,5,5,5,5,4,5,5,5,5,5,6,4,4,4,4, 4,4,4,4,6,4,4,4,4,4,3,2,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, }; static unsigned short stb__arial_bold_7_latin1_h[224]={ 0,5,3,6,6,6,6,3,7,7,3,4,3,2, 1,6,6,5,5,6,5,6,6,5,6,6,4,6,4,3,4,5,7,5,5,6,5,5,5,6,5,5,6,5, 5,5,5,6,5,6,5,6,5,6,5,5,5,5,5,7,6,7,3,2,2,5,6,5,6,5,5,6,5,5, 7,5,5,4,4,5,6,6,4,5,6,5,4,4,4,6,4,7,7,7,2,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,6,7,6,4,5, 7,7,2,6,3,4,3,2,6,2,3,5,3,3,2,6,7,2,2,3,3,4,6,6,6,6,6,6,6,6, 6,6,5,7,6,6,6,6,6,6,6,6,5,6,7,7,7,7,7,4,6,7,7,7,7,6,5,6,6,6, 6,6,6,6,5,6,6,6,6,6,5,5,5,5,6,5,6,6,6,6,6,4,5,6,6,6,6,7,7,7, }; static unsigned short stb__arial_bold_7_latin1_s[224]={ 130,83,126,111,116,121,138,116,16,24,133, 82,92,152,173,160,164,64,10,192,42,144,169,129,203,128,74,253,69,95,59, 188,33,198,210,174,221,247,1,197,227,244,213,150,145,134,233,149,216,235,204, 1,193,241,181,174,168,161,156,41,252,74,87,167,164,121,180,112,155,99,95, 208,86,126,82,74,71,52,6,59,247,222,252,37,6,25,37,26,21,230,16, 86,90,93,147,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77, 77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,130,227,19, 217,47,20,121,77,143,185,107,32,111,152,104,137,122,15,119,130,155,133,115, 158,161,104,100,64,90,83,76,71,65,59,53,47,41,35,104,103,20,15,10, 5,1,250,246,242,52,231,27,44,50,56,62,11,195,68,97,124,109,97,47, 160,155,25,180,30,190,237,30,130,145,165,170,175,117,68,91,79,140,140,185, 135,201,206,211,42,239,216,221,226,150,11,6,1, }; static unsigned short stb__arial_bold_7_latin1_t[224]={ 8,16,23,9,9,9,9,23,1,1,23, 23,23,23,23,9,9,16,16,9,16,9,9,16,9,9,23,1,23,23,23, 16,1,16,16,9,16,16,23,9,16,16,9,16,16,16,16,9,16,9,16, 16,16,9,16,16,16,16,16,1,9,1,23,23,23,16,9,16,9,16,16, 9,16,16,1,16,16,23,23,16,9,9,16,16,16,16,23,23,23,9,23, 1,1,1,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23, 23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,8,9,1, 9,23,16,1,1,23,9,23,23,23,23,9,23,23,16,23,23,23,9,1, 23,23,23,23,23,9,9,9,9,9,9,9,9,9,9,16,1,9,9,9, 9,9,1,1,1,16,1,1,1,1,1,1,23,1,1,1,1,1,9,16, 1,1,9,1,9,1,1,16,1,1,1,1,1,16,16,16,16,1,16,1, 1,1,1,1,23,16,1,1,1,1,1,1,1, }; static unsigned short stb__arial_bold_7_latin1_a[224]={ 28,33,48,56,56,89,72,24, 33,33,39,59,28,33,28,28,56,56,56,56,56,56,56,56, 56,56,33,33,59,59,59,61,98,72,72,72,72,67,61,78, 72,28,56,72,61,84,72,78,67,78,72,67,61,72,67,95, 67,67,61,33,28,33,59,56,33,56,61,56,61,56,33,61, 61,28,28,56,28,89,61,61,61,61,39,56,33,61,56,78, 56,56,50,39,28,39,59,75,75,75,75,75,75,75,75,75, 75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75, 75,75,75,75,75,75,75,75,28,33,56,56,56,56,28,56, 33,74,37,56,59,33,74,55,40,55,33,33,33,58,56,28, 33,33,37,56,84,84,84,61,72,72,72,72,72,72,100,72, 67,67,67,67,28,28,28,28,72,72,78,78,78,78,78,59, 78,72,72,72,72,67,67,61,56,56,56,56,56,56,89,56, 56,56,56,56,28,28,28,28,61,61,61,61,61,61,61,55, 61,61,61,61,61,56,61,56, }; // Call this function with // font: NULL or array length // data: NULL or specified size // height: STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT or STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT_POW2 // return value: spacing between lines static void stb_font_arial_bold_7_latin1(stb_fontchar font[STB_FONT_arial_bold_7_latin1_NUM_CHARS], unsigned char data[STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT][STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH], int height) { int i,j; if (data != 0) { unsigned int *bits = stb__arial_bold_7_latin1_pixels; unsigned int bitpack = *bits++, numbits = 32; for (i=0; i < STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH*height; ++i) data[0][i] = 0; // zero entire bitmap for (j=1; j < STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT-1; ++j) { for (i=1; i < STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH-1; ++i) { unsigned int value; if (numbits==0) bitpack = *bits++, numbits=32; value = bitpack & 1; bitpack >>= 1, --numbits; if (value) { if (numbits < 3) bitpack = *bits++, numbits = 32; data[j][i] = (bitpack & 7) * 0x20 + 0x1f; bitpack >>= 3, numbits -= 3; } else { data[j][i] = 0; } } } } // build font description if (font != 0) { float recip_width = 1.0f / STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH; float recip_height = 1.0f / height; for (i=0; i < STB_FONT_arial_bold_7_latin1_NUM_CHARS; ++i) { // pad characters so they bilerp from empty space around each character font[i].s0 = (stb__arial_bold_7_latin1_s[i]) * recip_width; font[i].t0 = (stb__arial_bold_7_latin1_t[i]) * recip_height; font[i].s1 = (stb__arial_bold_7_latin1_s[i] + stb__arial_bold_7_latin1_w[i]) * recip_width; font[i].t1 = (stb__arial_bold_7_latin1_t[i] + stb__arial_bold_7_latin1_h[i]) * recip_height; font[i].x0 = stb__arial_bold_7_latin1_x[i]; font[i].y0 = stb__arial_bold_7_latin1_y[i]; font[i].x1 = stb__arial_bold_7_latin1_x[i] + stb__arial_bold_7_latin1_w[i]; font[i].y1 = stb__arial_bold_7_latin1_y[i] + stb__arial_bold_7_latin1_h[i]; font[i].advance_int = (stb__arial_bold_7_latin1_a[i]+8)>>4; font[i].s0f = (stb__arial_bold_7_latin1_s[i] - 0.5f) * recip_width; font[i].t0f = (stb__arial_bold_7_latin1_t[i] - 0.5f) * recip_height; font[i].s1f = (stb__arial_bold_7_latin1_s[i] + stb__arial_bold_7_latin1_w[i] + 0.5f) * recip_width; font[i].t1f = (stb__arial_bold_7_latin1_t[i] + stb__arial_bold_7_latin1_h[i] + 0.5f) * recip_height; font[i].x0f = stb__arial_bold_7_latin1_x[i] - 0.5f; font[i].y0f = stb__arial_bold_7_latin1_y[i] - 0.5f; font[i].x1f = stb__arial_bold_7_latin1_x[i] + stb__arial_bold_7_latin1_w[i] + 0.5f; font[i].y1f = stb__arial_bold_7_latin1_y[i] + stb__arial_bold_7_latin1_h[i] + 0.5f; font[i].advance = stb__arial_bold_7_latin1_a[i]/16.0f; } } } #ifndef STB_SOMEFONT_CREATE #define STB_SOMEFONT_CREATE stb_font_arial_bold_7_latin1 #define STB_SOMEFONT_BITMAP_WIDTH STB_FONT_arial_bold_7_latin1_BITMAP_WIDTH #define STB_SOMEFONT_BITMAP_HEIGHT STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT #define STB_SOMEFONT_BITMAP_HEIGHT_POW2 STB_FONT_arial_bold_7_latin1_BITMAP_HEIGHT_POW2 #define STB_SOMEFONT_FIRST_CHAR STB_FONT_arial_bold_7_latin1_FIRST_CHAR #define STB_SOMEFONT_NUM_CHARS STB_FONT_arial_bold_7_latin1_NUM_CHARS #define STB_SOMEFONT_LINE_SPACING STB_FONT_arial_bold_7_latin1_LINE_SPACING #endif