ref: def6bc8aa2a70c6dd9f7974ca12992efd32b2ebd
dir: /otf.h.in/
/* this file is generated. do not modify. */
typedef struct Otf Otf;
#ifdef __unix__
#include <stdint.h>
typedef int8_t s8int;
typedef int16_t s16int;
typedef int32_t s32int;
typedef int64_t s64int;
typedef uint8_t u8int;
typedef uint16_t u16int;
typedef uint32_t u32int;
typedef uint64_t u64int;
char *otferrstr(void);
#else
#pragma incomplete Otf
#endif
typedef struct Otfile Otfile;
struct Otfile {
void *aux;
int (*seek)(void *aux, int off, int whence);
int (*read)(void *aux, void *dst, int sz);
int (*print)(void *aux, const char *fmt, ...);
};
typedef struct ComponentGlyph ComponentGlyph;
enum {
CGLYPH_FL_ROUND_TO_GRID_XY = 1<<2,
CGLYPH_FL_SCALE = 1<<3,
CGLYPH_FL_MORE_COMPONENTS = 1<<5,
CGLYPH_FL_SCALE_XY = 1<<6,
CGLYPH_FL_2X2_TRANSFORM = 1<<7,
CGLYPH_FL_INSTRUCTIONS = 1<<8,
CGLYPH_FL_METRICS = 1<<9,
CGLYPH_FL_OVERLAP_COMPOUND = 1<<10,
CGLYPH_FL_SCALED_COMPONENT_OFFSET = 1<<11,
CGLYPH_FL_UNSCALED_COMPONENT_OFFSET = 1<<12,
};
struct ComponentGlyph {
u16int flags;
u16int glyphIndex;
int arg1;
int arg2;
float scale, scaleX, scale01, scale10, scaleY;
u16int numInstr;
u8int *instr;
ComponentGlyph *next;
};
typedef struct Point Point;
struct Point {
int x;
int y;
int onCurve;
};
typedef struct SimpleGlyph SimpleGlyph;
struct SimpleGlyph {
int numEndPtsOfContours;
u16int *endPtsOfContours;
u16int instructionLength;
u8int *instructions;
int numPoints;
Point *points;
};
extern int indentΔ;
Otf *otfopen(Otfile *in);
void otfprint(Otf *o, Otfile *out, int indent);
void otfclose(Otf *o);
/* FIXME these will go, this is for debugging and designing the drawing logic */
typedef struct Glyf Glyf;
Glyf *otfglyf(Otf *o, int index);
int otfglyfnum(Otf *o);
u8int *otfdrawglyf(Glyf *g, int ppem, int *wo, int *ho);