21#define FONT_THUMB_VERSION "1.0.1"
28 const float col[4] = {1.0f, 1.0f, 1.0f, 0.0f};
51 int font_id = (filepath[0] !=
'<') ?
BLF_load(filepath) : 0;
55 const char sample[] =
"ABCDEFGH\nabcdefg123";
64 float scale =
float(width) / name_w;
69 int height =
int(name_h * 1.3f);
72 const float col[4] = {1.0f, 1.0f, 1.0f, 0.0f};
80 BLF_buffer(font_id,
nullptr,
nullptr, 0, 0,
nullptr);
void BLF_size(int fontid, float size)
void BLF_draw_buffer(int fontid, const char *str, size_t str_len, ResultBLF *r_info=nullptr) ATTR_NONNULL(2)
void BLF_width_and_height(int fontid, const char *str, size_t str_len, float *r_width, float *r_height) ATTR_NONNULL()
void BLF_buffer_col(int fontid, const float rgba[4]) ATTR_NONNULL(2)
void BLF_buffer(int fontid, float *fbuf, unsigned char *cbuf, int w, int h, ColorManagedDisplay *display)
void BLF_unload_id(int fontid)
int BLF_load(const char *filepath) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void BLF_enable(int fontid, int option)
bool BLF_thumb_preview(const char *filepath, unsigned char *buf, int w, int h, int channels) ATTR_NONNULL()
void BLF_position(int fontid, float x, float y, float z)
char * BLI_hash_md5_to_hexdigest(const void *resblock, char r_hex_digest[33])
void * BLI_hash_md5_buffer(const char *buffer, size_t len, void *resblock)
void IMB_rectfill(ImBuf *drect, const float col[4])
Contains defines and structs used throughout the imbuf module.
draw_view in_light_buf[] float
draw_view push_constant(Type::INT, "radiance_src") .push_constant(Type capture_info_buf storage_buf(1, Qualifier::READ, "ObjectBounds", "bounds_buf[]") .push_constant(Type draw_view int
struct ImBuf * IMB_allocImBuf(unsigned int, unsigned int, unsigned char, unsigned int)
void IMB_freeImBuf(ImBuf *)
ImBufFloatBuffer float_buffer
ImBufByteBuffer byte_buffer
ImBuf * IMB_thumb_load_font(const char *filepath, uint x, uint y)
bool IMB_thumb_load_font_get_hash(char *r_hash)
#define FONT_THUMB_VERSION
ImBuf * IMB_font_preview(const char *filepath, uint width, const float color[4])