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:
authorJacques Lucke <mail@jlucke.com>2018-10-18 16:43:06 +0300
committerJacques Lucke <mail@jlucke.com>2018-10-18 16:43:06 +0300
commit41216d5ad4c722e2ad9f15c968af454fc7566d5e (patch)
treef68fe3e1dd32a2d651b6678a1783e165ce2e70c8 /source/blender/blenlib/intern/freetypefont.c
parentcfdd902d2d5d560262d1218861ad1a4469c5259f (diff)
Cleanup: Remove more #if 0 blocks
Continuation of https://developer.blender.org/D3802 Reviewers: brecht Differential Revision: https://developer.blender.org/D3808
Diffstat (limited to 'source/blender/blenlib/intern/freetypefont.c')
-rw-r--r--source/blender/blenlib/intern/freetypefont.c67
1 files changed, 0 insertions, 67 deletions
diff --git a/source/blender/blenlib/intern/freetypefont.c b/source/blender/blenlib/intern/freetypefont.c
index 9045012af00..0bed7d42e9f 100644
--- a/source/blender/blenlib/intern/freetypefont.c
+++ b/source/blender/blenlib/intern/freetypefont.c
@@ -291,14 +291,6 @@ static VFontData *objfnt_to_ftvfontdata(PackedFile *pf)
const char *fontname;
VFontData *vfd;
-#if 0
- FT_CharMap found = 0;
- FT_CharMap charmap;
- FT_UShort my_platform_id = TT_PLATFORM_MICROSOFT;
- FT_UShort my_encoding_id = TT_MS_ID_UNICODE_CS;
- int n;
-#endif
-
/* load the freetype font */
err = FT_New_Memory_Face(library,
pf->data,
@@ -308,25 +300,6 @@ static VFontData *objfnt_to_ftvfontdata(PackedFile *pf)
if (err) return NULL;
-#if 0
- for (n = 0; n < face->num_charmaps; n++)
- {
- charmap = face->charmaps[n];
- if (charmap->platform_id == my_platform_id &&
- charmap->encoding_id == my_encoding_id)
- {
- found = charmap;
- break;
- }
- }
-
- if (!found) { return NULL; }
-
- /* now, select the charmap for the face object */
- err = FT_Set_Charmap(face, found);
- if (err) { return NULL; }
-#endif
-
/* allocate blender font */
vfd = MEM_callocN(sizeof(*vfd), "FTVFontData");
@@ -410,13 +383,6 @@ static int check_freetypefont(PackedFile *pf)
FT_Face face;
FT_GlyphSlot glyph;
FT_UInt glyph_index;
-#if 0
- FT_CharMap charmap;
- FT_CharMap found;
- FT_UShort my_platform_id = TT_PLATFORM_MICROSOFT;
- FT_UShort my_encoding_id = TT_MS_ID_UNICODE_CS;
- int n;
-#endif
int success = 0;
err = FT_New_Memory_Face(library,
@@ -429,23 +395,6 @@ static int check_freetypefont(PackedFile *pf)
//XXX error("This is not a valid font");
}
else {
-
-#if 0
- for (n = 0; n < face->num_charmaps; n++) {
- charmap = face->charmaps[n];
- if (charmap->platform_id == my_platform_id && charmap->encoding_id == my_encoding_id) {
- found = charmap;
- break;
- }
- }
-
- if (!found) { return 0; }
-
- /* now, select the charmap for the face object */
- err = FT_Set_Charmap(face, found);
- if (err) { return 0; }
-#endif
-
glyph_index = FT_Get_Char_Index(face, 'A');
err = FT_Load_Glyph(face, glyph_index, FT_LOAD_NO_SCALE | FT_LOAD_NO_BITMAP);
if (err) {
@@ -550,22 +499,6 @@ VChar *BLI_vfontchar_copy(const VChar *vchar_src, const int UNUSED(flag))
return vchar_dst;
}
-#if 0
-
-/* Freetype2 Outline struct */
-
-typedef struct FT_Outline_ {
- short n_contours; /* number of contours in glyph */
- short n_points; /* number of points in the glyph */
-
- FT_Vector *points; /* the outline's points */
- char *tags; /* the points flags */
- short *contours; /* the contour end points */
-
- int flags; /* outline masks */
-} FT_Outline;
-
-#endif
/*
* from: http://www.freetype.org/freetype2/docs/glyphs/glyphs-6.html#section-1