Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Borghetti <bdiego@gmail.com>2009-05-06 03:10:32 +0400
committerDiego Borghetti <bdiego@gmail.com>2009-05-06 03:10:32 +0400
commit405cf80eb8dc2df8ae160aee70aef34052add24a (patch)
treef03cc27e95bdf91b25ea9d2a0dffb28ccef666be /source/blender/blenfont/BLF_api.h
parent71c38978e14ebf3522fe60fc239ad04f10ef30ab (diff)
Big, big commit!!
1) Remove WITH_FREETYPE2 from code, so now blender always need freetype2 2) Remove the old bmfont 3) Remove ftfont and bFTGL library 4) Implement a new BLF_draw_default function for place that still need/use the old BMF api. I try to update both, scons and cmake, but I only can test with make, so hope all work fine. MSVC is broken, but I don't have Windows, things to search and fix are any reference to WITH_FREETYPE2, FTGL and BMFONT (take in care that blenkernel also have a BKE_bmfont.h, this don't have anything to do with bmfont). Always have to link/include the freetype2 library Remove any reference to libbmfont Remove any reference to libftfont Remove any reference to libbftgl (or libbFTGL)
Diffstat (limited to 'source/blender/blenfont/BLF_api.h')
-rw-r--r--source/blender/blenfont/BLF_api.h25
1 files changed, 14 insertions, 11 deletions
diff --git a/source/blender/blenfont/BLF_api.h b/source/blender/blenfont/BLF_api.h
index 510ff550acc..516ecd102d6 100644
--- a/source/blender/blenfont/BLF_api.h
+++ b/source/blender/blenfont/BLF_api.h
@@ -31,7 +31,7 @@
struct rctf;
-int BLF_init(void);
+int BLF_init(int points, int dpi);
void BLF_exit(void);
int BLF_load(char *name);
@@ -43,15 +43,14 @@ int BLF_load_mem(char *name, unsigned char *mem, int mem_size);
void BLF_set(int fontid);
int BLF_get(void);
-/*
- * Return the font type, can be freetype2 or internal, -1 if
- * some error happen (no current font).
- */
-int BLF_type_get(void);
-
void BLF_aspect(float aspect);
void BLF_position(float x, float y, float z);
void BLF_size(int size, int dpi);
+
+/* Draw the string using the default font, size and dpi. */
+void BLF_draw_default(float x, float y, float z, char *str);
+
+/* Draw the string using the current font. */
void BLF_draw(char *str);
/*
@@ -69,6 +68,14 @@ float BLF_width(char *str);
float BLF_height(char *str);
/*
+ * and this two function return the width and height
+ * of the string, using the default font and both value
+ * are multiplied by the aspect of the font.
+ */
+float BLF_width_default(char *str);
+float BLF_height_default(char *str);
+
+/*
* By default, rotation and clipping are disable and
* have to be enable/disable using BLF_enable/disable.
*/
@@ -112,8 +119,4 @@ void BLF_dir_free(char **dirs, int count);
#define BLF_MODE_TEXTURE 0
#define BLF_MODE_BITMAP 1
-/* font->type */
-#define BLF_FONT_FREETYPE2 0
-#define BLF_FONT_INTERNAL 1
-
#endif /* BLF_API_H */