4 #include <dbox/lcd-ks0713.h>
8 #define LCD_DEV "/dev/dbox/lcd0"
12 #include FT_FREETYPE_H
14 #include FT_CACHE_SMALL_BITMAPS_H
15 #define FONT "/share/fonts/pakenham.ttf"
18 typedef unsigned char raw_display_t
[LCD_ROWS
*8][LCD_COLS
];
27 #if FREETYPE_MAJOR == 2 && FREETYPE_MINOR == 0
30 FTC_ImageTypeRec desc
;
33 FT_UInt prev_glyphindex
;
35 int RenderChar(FT_ULong currentchar
, int sx
, int sy
, int ex
, int state
);
36 int GetStringLen(unsigned char *string
);
39 unsigned char lcd
[LCD_ROWS
][LCD_COLS
];
42 void draw_point(const int x
, const int y
, const int state
);
43 int invalid_col(int x
);
44 int invalid_row(int y
);
48 enum {PIXEL_ON
= LCD_PIXEL_ON
, PIXEL_OFF
= LCD_PIXEL_OFF
, PIXEL_INV
= LCD_PIXEL_INV
};
49 enum {LEFT
, CENTER
, RIGHT
};
55 FT_Error
FTC_Face_Requester(FTC_FaceID face_id
, FT_Face
* aface
);
56 void RenderString(std::string word
, int sx
, int sy
, int maxwidth
, int layout
, int size
, int state
);
58 void draw_char(int x
, int y
, char c
);
59 void draw_string(int x
, int y
, const char *string
);
64 void draw_line(const int x1
, const int y1
, const int x2
, const int y2
, int state
);
65 void draw_fill_rect (int left
,int top
,int right
,int bottom
, int state
);
66 bool load_png(const char * const filename
);