17 #include FT_FREETYPE_H
21 #include FT_ADVANCES_H
22 #include FT_MULTIPLE_MASTERS_H
54 return (FT_Fixed)(lround(val * 65536.0));
97 FT_UInt gindex = FT_Get_Char_Index(font->
face,
U'0');
100 FT_Get_Advance(font->
face, gindex, FT_LOAD_NO_HINTING, &advance);
177 if (
g->c == charcode) {
193 g->idx = glyph_index;
195 g->pos[0] =
glyph->bitmap_left;
196 g->pos[1] =
glyph->bitmap_top;
197 g->dims[0] = (
int)
glyph->bitmap.width;
198 g->dims[1] = (int)
glyph->bitmap.rows;
199 g->pitch =
glyph->bitmap.pitch;
202 FT_Outline_Get_CBox(&(
glyph->outline), &bbox);
203 g->box_xmin = (
ft_pix)bbox.xMin;
204 g->box_xmax = (
ft_pix)bbox.xMax;
205 g->box_ymin = (
ft_pix)bbox.yMin;
206 g->box_ymax = (
ft_pix)bbox.yMax;
212 const int buffer_size = (int)(
glyph->bitmap.width *
glyph->bitmap.rows);
213 if (buffer_size != 0) {
216 for (
int i = 0; i < buffer_size; i++) {
217 glyph->bitmap.buffer[i] =
glyph->bitmap.buffer[i] ? 255 : 0;
220 g->bitmap =
MEM_mallocN((
size_t)buffer_size,
"glyph bitmap");
221 memcpy(
g->bitmap,
glyph->bitmap.buffer, (
size_t)buffer_size);
277 {0x1000, 0x109F, 74},
278 {0x10A0, 0x10FF, 26},
279 {0x1100, 0x11FF, 28},
280 {0x1200, 0x139F, 75},
281 {0x13A0, 0x13FF, 76},
282 {0x1400, 0x167F, 77},
283 {0x1680, 0x169F, 78},
284 {0x16A0, 0x16FF, 79},
285 {0x1700, 0x171F, 84},
286 {0x1720, 0x173F, 84},
287 {0x1740, 0x175F, 84},
288 {0x1760, 0x177F, 84},
289 {0x1780, 0x17FF, 80},
290 {0x1800, 0x18AF, 81},
291 {0x1900, 0x194F, 93},
292 {0x1950, 0x197F, 94},
293 {0x1980, 0x19DF, 95},
294 {0x19E0, 0x19FF, 80},
295 {0x1A00, 0x1A1F, 96},
296 {0x1A20, 0x1AAF, -1},
297 {0x1B00, 0x1B7F, 27},
298 {0x1B80, 0x1BBF, 112},
299 {0x1BC0, 0x1BFF, -1},
300 {0x1C00, 0x1C4F, 113},
301 {0x1C50, 0x1C7F, 114},
304 {0x1E00, 0x1EFF, 29},
305 {0x1F00, 0x1FFF, 30},
306 {0x2000, 0x206F, 31},
307 {0x2070, 0x209F, 32},
308 {0x20A0, 0x20CF, 33},
309 {0x20D0, 0x20FF, 34},
310 {0x2100, 0x214F, 35},
311 {0x2150, 0x218F, 36},
312 {0x2190, 0x21FF, 37},
313 {0x2200, 0x22FF, 38},
314 {0x2300, 0x23FF, 39},
315 {0x2400, 0x243F, 40},
316 {0x2440, 0x245F, 41},
317 {0x2460, 0x24FF, 42},
318 {0x2500, 0x257F, 43},
319 {0x2580, 0x259F, 44},
320 {0x25A0, 0x25FF, 45},
321 {0x2600, 0x26FF, 46},
322 {0x2700, 0x27BF, 47},
323 {0x27C0, 0x27EF, 38},
324 {0x27F0, 0x27FF, 37},
325 {0x2800, 0x28FF, 82},
326 {0x2900, 0x297F, 37},
327 {0x2980, 0x2AFF, 38},
328 {0x2B00, 0x2BFF, 37},
329 {0x2C00, 0x2C5F, 97},
330 {0x2C60, 0x2C7F, 29},
332 {0x2D00, 0x2D2F, 26},
333 {0x2D30, 0x2D7F, 98},
334 {0x2D80, 0x2DDF, 75},
336 {0x2E00, 0x2E7F, 31},
337 {0x2E80, 0x2FFF, 59},
338 {0x3000, 0x303F, 48},
339 {0x3040, 0x309F, 49},
340 {0x30A0, 0x30FF, 50},
341 {0x3100, 0x312F, 51},
342 {0x3130, 0x318F, 52},
343 {0x3190, 0x319F, 59},
344 {0x31A0, 0x31BF, 51},
345 {0x31C0, 0x31EF, 59},
346 {0x31F0, 0x31FF, 50},
347 {0x3200, 0x32FF, 54},
348 {0x3300, 0x33FF, 55},
349 {0x3400, 0x4DBF, 59},
350 {0x4DC0, 0x4DFF, 99},
351 {0x4E00, 0x9FFF, 59},
352 {0xA000, 0xA4CF, 83},
353 {0xA4D0, 0xA4FF, -1},
354 {0xA500, 0xA63F, 12},
356 {0xA6A0, 0xA6FF, -1},
358 {0xA720, 0xA7FF, 29},
359 {0xA800, 0xA82F, 100},
360 {0xA840, 0xA87F, 53},
361 {0xA880, 0xA8DF, 115},
362 {0xA900, 0xA92F, 116},
363 {0xA930, 0xA95F, 117},
364 {0xA960, 0xA97F, 56},
365 {0xA980, 0xA9DF, -1},
366 {0xA9E0, 0xA9FF, 74},
367 {0xAA00, 0xAA5F, 118},
368 {0xAA60, 0xAA7F, 74},
369 {0xAA80, 0xAADF, -1},
370 {0xAAE0, 0xAAFF, -1},
371 {0xAB00, 0xAB2F, 75},
372 {0xAB70, 0xABBF, 76},
373 {0xABC0, 0xABFF, -1},
374 {0xAC00, 0xD7AF, 56},
375 {0xD800, 0xDFFF, 57},
376 {0xE000, 0xF6FF, 60},
377 {0xE700, 0xEFFF, -1},
378 {0xF000, 0xF8FF, -1},
379 {0xF900, 0xFAFF, 61},
380 {0xFB00, 0xFB4F, 62},
381 {0xFB50, 0xFDFF, 63},
382 {0xFE00, 0xFE0F, 91},
383 {0xFE10, 0xFE1F, 65},
384 {0xFE20, 0xFE2F, 64},
385 {0xFE30, 0xFE4F, 65},
386 {0xFE50, 0xFE6F, 66},
387 {0xFE70, 0xFEFF, 67},
388 {0xFF00, 0xFFEF, 68},
389 {0xFFF0, 0xFFFF, 69},
390 {0x10000, 0x1013F, 101},
391 {0x10140, 0x1018F, 102},
392 {0x10190, 0x101CF, 119},
393 {0x101D0, 0x101FF, 120},
394 {0x10280, 0x1029F, 121},
395 {0x102A0, 0x102DF, 121},
396 {0x10300, 0x1032F, 85},
397 {0x10330, 0x1034F, 86},
398 {0x10350, 0x1037F, -1},
399 {0x10380, 0x1039F, 103},
400 {0x103A0, 0x103DF, 104},
401 {0x10400, 0x1044F, 87},
402 {0x10450, 0x1047F, 105},
403 {0x10480, 0x104AF, 106},
404 {0x104B0, 0x104FF, -1},
405 {0x10500, 0x1052F, -1},
406 {0x10530, 0x1056F, -1},
407 {0x10570, 0x105BF, -1},
408 {0x10600, 0x1077F, -1},
409 {0x10780, 0x107BF, 3},
410 {0x10800, 0x1083F, 107},
411 {0x10840, 0x1085F, -1},
412 {0x10860, 0x1087F, -1},
413 {0x10880, 0x108AF, -1},
414 {0x108E0, 0x108FF, -1},
415 {0x10900, 0x1091F, 58},
416 {0x10920, 0x1093F, 121},
417 {0x10980, 0x1099F, -1},
418 {0x109A0, 0x109FF, -1},
419 {0x10A00, 0x10A5F, 108},
420 {0x10A60, 0x10A7F, -1},
421 {0x10A80, 0x10A9F, -1},
422 {0x10AC0, 0x10AFF, -1},
423 {0x10B00, 0x10B3F, -1},
424 {0x10B40, 0x10B5F, -1},
425 {0x10B60, 0x10B7F, -1},
426 {0x10B80, 0x10BAF, -1},
427 {0x10C00, 0x10C4F, -1},
428 {0x10C80, 0x10CFF, -1},
429 {0x10D00, 0x10D3F, -1},
430 {0x108E0, 0x10E7F, -1},
431 {0x10E80, 0x10EBF, -1},
432 {0x10F00, 0x10F2F, -1},
433 {0x10F30, 0x10F6F, -1},
434 {0x10F70, 0x10FAF, -1},
435 {0x10FB0, 0x10FDF, -1},
436 {0x10FE0, 0x10FFF, -1},
437 {0x11000, 0x1107F, -1},
438 {0x11080, 0x110CF, -1},
439 {0x110D0, 0x110FF, -1},
440 {0x11100, 0x1114F, -1},
441 {0x11150, 0x1117F, -1},
442 {0x11180, 0x111DF, -1},
443 {0x111E0, 0x111FF, -1},
444 {0x11200, 0x1124F, -1},
445 {0x11280, 0x112AF, -1},
446 {0x112B0, 0x112FF, -1},
447 {0x11300, 0x1137F, -1},
448 {0x11400, 0x1147F, -1},
449 {0x11480, 0x114DF, -1},
450 {0x11580, 0x115FF, -1},
451 {0x11600, 0x1165F, -1},
452 {0x11660, 0x1167F, 81},
453 {0x11680, 0x116CF, -1},
454 {0x11700, 0x1174F, -1},
455 {0x11800, 0x1184F, -1},
456 {0x118A0, 0x118FF, -1},
457 {0x11900, 0x1195F, -1},
458 {0x119A0, 0x119FF, -1},
459 {0x11A00, 0x11A4F, -1},
460 {0x11A50, 0x11AAF, -1},
461 {0x11AB0, 0x11ABF, 77},
462 {0x11AC0, 0x11AFF, -1},
463 {0x11C00, 0x11C6F, -1},
464 {0x11C70, 0x11CBF, -1},
465 {0x11D00, 0x11D5F, -1},
466 {0x11D60, 0x11DAF, -1},
467 {0x11EE0, 0x11EFF, -1},
468 {0x11FB0, 0x11FBF, -1},
469 {0x11FC0, 0x11FFF, 20},
470 {0x12000, 0x1254F, 110},
471 {0x12F90, 0x12FFF, -1},
472 {0x13000, 0x1343F, -1},
473 {0x14400, 0x1467F, -1},
474 {0x16800, 0x16A3F, -1},
475 {0x16A40, 0x16A6F, -1},
476 {0x16A70, 0x16ACF, -1},
477 {0x16AD0, 0x16AFF, -1},
478 {0x16B00, 0x16B8F, -1},
479 {0x16E40, 0x16E9F, -1},
480 {0x16F00, 0x16F9F, -1},
481 {0x16FE0, 0x16FFF, -1},
482 {0x17000, 0x18AFF, -1},
483 {0x1B170, 0x1B2FF, -1},
484 {0x1BC00, 0x1BC9F, -1},
485 {0x1D000, 0x1D24F, 88},
486 {0x1D2E0, 0x1D2FF, -1},
487 {0x1D300, 0x1D35F, 109},
488 {0x1D360, 0x1D37F, 111},
489 {0x1D400, 0x1D7FF, 89},
490 {0x1E2C0, 0x1E2FF, -1},
491 {0x1E800, 0x1E8DF, -1},
492 {0x1E900, 0x1E95F, -1},
493 {0x1EC70, 0x1ECBF, -1},
494 {0x1F000, 0x1F02F, 122},
495 {0x1F030, 0x1F09F, 122},
496 {0x1F600, 0x1F64F, -1},
497 {0x20000, 0x2A6DF, 59},
498 {0x2F800, 0x2FA1F, 61},
499 {0xE0000, 0xE007F, 92},
500 {0xE0100, 0xE01EF, 91},
501 {0xF0000, 0x10FFFD, 90}};
506 if (charcode < 0x80) {
539 int coverage_bit = -1;
545 if (coverage_bit < 0 && charcode > 0xFFFF) {
556 if (coverage_bit < 0) {
568 FT_UInt glyph_index = FT_Get_Char_Index((*font)->face, charcode);
587 glyph_index = FT_Get_Char_Index(f->
face, charcode);
597 glyph_index = FT_Get_Char_Index(last_resort->
face, charcode);
615 load_flags = FT_LOAD_TARGET_MONO;
618 load_flags = FT_LOAD_NO_BITMAP;
620 load_flags |= FT_LOAD_TARGET_NORMAL | FT_LOAD_NO_HINTING;
623 load_flags |= FT_LOAD_TARGET_LIGHT;
626 load_flags |= FT_LOAD_TARGET_NORMAL;
631 load_flags |= FT_LOAD_TARGET_NORMAL | FT_LOAD_NO_HINTING;
635 if (FT_Load_Glyph(font->
face, glyph_index, load_flags) == FT_Err_Ok) {
636 return font->
face->glyph;
649 render_mode = FT_RENDER_MODE_MONO;
652 render_mode = FT_RENDER_MODE_NORMAL;
656 FT_Error
err = FT_Render_Glyph(
glyph, render_mode);
657 if (
err != FT_Err_Ok) {
661 FT_Bitmap tempbitmap;
666 FT_Bitmap_New(&tempbitmap);
669 err += FT_Bitmap_Convert(font->
ft_lib, &
glyph->bitmap, &tempbitmap, 1);
671 err += FT_Bitmap_Done(font->
ft_lib, &tempbitmap);
674 if (
err ||
glyph->format != FT_GLYPH_FORMAT_BITMAP) {
700 for (
int i = 0; i < (int)variations->num_axis; i++) {
701 if (variations->axis[i].tag == tag) {
703 return &(variations->axis)[i];
718 FT_Fixed value = axis->def;
721 value += (FT_Fixed)((
double)(axis->maximum - axis->def) * factor);
723 else if (factor < 0) {
725 value += (FT_Fixed)((
double)(axis->def - axis->minimum) * factor);
764 CLAMP(int_value, axis->minimum, axis->maximum);
765 coords[axis_index] = int_value;
784 if (
glyph->format == FT_GLYPH_FORMAT_OUTLINE) {
786 const FT_Pos average_width = FT_MulFix(
glyph->face->units_per_EM,
787 glyph->face->size->metrics.x_scale);
788 FT_Pos change = (FT_Pos)((
float)average_width * factor * 0.1f);
789 FT_Outline_EmboldenXY(&
glyph->outline, change, change / 2);
792 FT_Outline_Translate(&
glyph->outline, change / -2, 0);
796 glyph->advance.x += change;
797 glyph->advance.y += change / 2;
813 if (
glyph->format == FT_GLYPH_FORMAT_OUTLINE) {
828 if (
glyph->format == FT_GLYPH_FORMAT_OUTLINE) {
829 float scale = (factor * 0.4f) + 1.0f;
831 FT_Outline_Transform(&
glyph->outline, &matrix);
832 glyph->advance.x = (FT_Pos)((
double)
glyph->advance.x * scale);
845 if (
glyph->advance.x > 0) {
846 const long int size =
glyph->face->size->metrics.height;
847 glyph->advance.x += (FT_Pos)(factor * (
float)
size / 6.0f);
858 if (
glyph->format == FT_GLYPH_FORMAT_OUTLINE) {
859 FT_Fixed current =
glyph->linearHoriAdvance;
860 FT_Fixed target =
width << 16;
861 if (target < current) {
862 const FT_Pos embolden = (FT_Pos)((current - target) >> 13);
864 FT_Outline_EmboldenXY(&
glyph->outline, embolden, 0);
865 const float scale = (
float)(target - (embolden << 9)) / (
float)current;
867 FT_Outline_Transform(&
glyph->outline, &matrix);
869 else if (target > current) {
871 FT_Outline_Translate(&
glyph->outline, (FT_Pos)((target - current) >> 11), 0);
894 if (glyph_font != settings_font) {
895 FT_Set_Char_Size(glyph_font->
face,
897 ((FT_F26Dot6)(settings_font->
size)) * 64,
900 glyph_font->
size = settings_font->
size;
901 glyph_font->
dpi = settings_font->
dpi;
905 bool weight_done =
false;
906 bool slant_done =
false;
907 bool width_done =
false;
908 bool spacing_done =
false;
957 if (weight != 0.0f && !weight_done) {
960 if (slant != 0.0f && !slant_done) {
963 if (
width != 0.0f && !width_done) {
966 if (spacing != 0.0f && !spacing_done) {
984 FontBLF *font_with_glyph = font;
994 font, font_with_glyph, glyph_index, charcode, gc->
fixed_width);
1021 rect->
xmin =
x +
g->pos[0];
1023 rect->
ymin =
y +
g->pos[1];
1051 const int glyph_size[2],
1077 const int glyph_size[2],
1084 int glyph_size_flag[2];
1086 glyph_size_flag[0] = -glyph_size[0];
1087 glyph_size_flag[1] = -glyph_size[1];
1093 const int glyph_size[2],
1100 int glyph_size_flag[2];
1102 glyph_size_flag[0] = -glyph_size[0];
1103 glyph_size_flag[1] = glyph_size[1];
1110 if ((!
g->dims[0]) || (!
g->dims[1])) {
1114 if (
g->glyph_cache ==
NULL) {
1121 int buff_size =
g->dims[0] *
g->dims[1];
1126 int h = bitmap_len /
w + 1;
1143 g->glyph_cache = gc;
1174 else if (font->
shadow <= 4) {
1198 switch (font->blur) {
typedef float(TangentPoint)[2]
void * BLI_pophead(ListBase *listbase) ATTR_NONNULL(1)
void BLI_addhead(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
MINLINE void copy_v4_fl4(float v[4], float x, float y, float z, float w)
MINLINE void copy_v4_v4_uchar(unsigned char r[4], const unsigned char a[4])
MINLINE void copy_v2_v2_int(int r[2], const int a[2])
void BLI_rcti_translate(struct rcti *rect, int x, int y)
bool BLI_rcti_inside_rcti(const rcti *rct_a, const rcti *rct_b)
Strict compiler flags for areas of code we want to ensure don't do conversions without us knowing abo...
size_t size_t int BLI_wcwidth(char32_t ucs) ATTR_WARN_UNUSED_RESULT
void BLI_spin_unlock(SpinLock *spin)
void BLI_spin_lock(SpinLock *spin)
int GPU_max_texture_size(void)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble y1
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint y
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble x2
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei width
void GPU_texture_free(GPUTexture *tex)
GPUTexture * GPU_texture_create_2d(const char *name, int w, int h, int mip_len, eGPUTextureFormat format, const float *data)
GPU_INLINE void * GPU_vertbuf_raw_step(GPUVertBufRaw *a)
Read Guarded memory(de)allocation.
#define MEM_reallocN(vmemh, len)
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position CLAMP
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert a color
FontBLF * global_font[BLF_MAX_FONT]
void blf_batch_draw(void)
static GlyphBLF * blf_glyph_cache_find_glyph(GlyphCacheBLF *gc, uint charcode)
static bool blf_glyph_transform_weight(FT_GlyphSlot glyph, float factor, bool monospaced)
static bool blf_font_has_coverage_bit(FontBLF *font, int coverage_bit)
static GlyphCacheBLF * blf_glyph_cache_find(FontBLF *font, float size, unsigned int dpi)
static eUnicodeBlock unicode_blocks[]
static bool blf_glyph_set_variation_normalized(FontBLF *font, FT_Fixed coords[], uint tag, float factor)
static void blf_texture5_draw(const unsigned char color_in[4], const int glyph_size[2], const int offset, const int x1, const int y1, const int x2, const int y2)
static bool blf_glyph_render_bitmap(FontBLF *font, FT_GlyphSlot glyph)
static bool blf_glyph_transform_spacing(FT_GlyphSlot glyph, float factor)
static void blf_glyph_cache_free(GlyphCacheBLF *gc)
static void blf_texture_draw(const unsigned char color[4], const int glyph_size[2], const int offset, const int x1, const int y1, const int x2, const int y2)
void blf_glyph_cache_clear(FontBLF *font)
static GlyphBLF * blf_glyph_cache_add_glyph(FontBLF *font, GlyphCacheBLF *gc, FT_GlyphSlot glyph, uint charcode, FT_UInt glyph_index)
static void blf_texture3_draw(const unsigned char color_in[4], const int glyph_size[2], const int offset, const int x1, const int y1, const int x2, const int y2)
void blf_glyph_draw(FontBLF *font, GlyphCacheBLF *gc, GlyphBLF *g, const int x, const int y)
static void blf_glyph_calc_rect_test(rcti *rect, GlyphBLF *g, const int x, const int y)
GlyphBLF * blf_glyph_ensure(FontBLF *font, GlyphCacheBLF *gc, uint charcode)
struct eUnicodeBlock eUnicodeBlock
static int blf_charcode_to_coverage_bit(uint charcode)
static FT_GlyphSlot blf_glyph_render(FontBLF *settings_font, FontBLF *glyph_font, FT_UInt glyph_index, uint charcode, int fixed_width)
static FT_GlyphSlot blf_glyph_load(FontBLF *font, FT_UInt glyph_index)
static FT_Fixed blf_factor_to_coordinate(FT_Var_Axis *axis, float factor)
static FT_Fixed to_16dot16(double val)
static bool blf_glyph_transform_monospace(FT_GlyphSlot glyph, int width)
static void blf_glyph_calc_rect_shadow(rcti *rect, GlyphBLF *g, const int x, const int y, FontBLF *font)
static GlyphCacheBLF * blf_glyph_cache_new(FontBLF *font)
static void blf_glyph_calc_rect(rcti *rect, GlyphBLF *g, const int x, const int y)
static bool blf_glyph_set_variation_float(FontBLF *font, FT_Fixed coords[], uint tag, float value)
void blf_glyph_cache_release(FontBLF *font)
static bool blf_glyph_transform_width(FT_GlyphSlot glyph, float factor)
static bool blf_glyph_transform_slant(FT_GlyphSlot glyph, float factor)
GlyphCacheBLF * blf_glyph_cache_acquire(FontBLF *font)
static FT_Var_Axis * blf_var_axis_by_tag(FT_MM_Var *variations, uint tag, int *axis_index)
void blf_glyph_free(GlyphBLF *g)
static eUnicodeBlock * blf_charcode_to_unicode_block(uint charcode)
static FT_UInt blf_glyph_index_from_charcode(FontBLF **font, const uint charcode)
unsigned int blf_hash(unsigned int val)
#define blf_variation_axis_slant
#define BLF_VARIATIONS_MAX
#define GLYPH_ASCII_TABLE_SIZE
#define blf_variation_axis_optsize
#define blf_variation_axis_spacing
#define blf_variation_axis_weight
#define BLF_BATCH_DRAW_LEN_MAX
#define blf_variation_axis_width
BLI_INLINE int ft_pix_to_int(ft_pix v)
SIMD_FORCE_INLINE btVector3 transform(const btVector3 &point) const
static DBVT_INLINE btScalar size(const btDbvtVolume &a)
SIMD_FORCE_INLINE const btScalar & w() const
Return the w value.
flat(Type::VEC4, "color_flat") .no_perspective(Type col offset fragColor glyph
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
void(* MEM_freeN)(void *vmemh)
void *(* MEM_callocN)(size_t len, const char *str)
void *(* MEM_mallocN)(size_t len, const char *str)
static const pxr::TfToken g("g", pxr::TfToken::Immortal)
struct GPUVertBufRaw pos_step col_step offset_step glyph_size_step
struct GlyphCacheBLF * glyph_cache
SpinLock * glyph_cache_mutex
unsigned char shadow_color[4]
struct GlyphBLF * glyph_ascii_table[GLYPH_ASCII_TABLE_SIZE]
struct GlyphCacheBLF * next
struct GlyphCacheBLF * prev