]> git.sesse.net Git - ccbs/blob - bigscreen/fonts.h
Find out which player is playing next (and which song), but don't print it yet.
[ccbs] / bigscreen / fonts.h
1 #ifndef _FONTS_H
2 #define _FONTS_H 1
3
4 #include <ft2build.h>
5 #include FT_FREETYPE_H
6 #include <vector>
7 #include "widestring.h"
8
9 struct TextDefer {
10         widestring str;
11         double size;
12         unsigned xpos, ypos;
13
14         bool changed;
15 };
16
17 void init_freetype();
18 unsigned my_draw_text(const widestring &str, unsigned char *buf, double size, int xpos = 0, int ypos = 0, int r = 255, int g = 255, int b = 255);
19
20 // draw_all_deferred_text draws every string in current that is not the same in old, in red
21 void my_draw_text_deferred(std::vector<TextDefer> &td, const widestring &str, double size, int xpos, int ypos);
22 void draw_all_deferred_text(unsigned char *buf, std::vector<TextDefer> &current, std::vector<TextDefer> &old);
23
24 #endif /* !defined(_FONTS_H) */