diff options
Diffstat (limited to 'test/05Font/main.cpp')
-rw-r--r-- | test/05Font/main.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/05Font/main.cpp b/test/05Font/main.cpp index 30b0e3d..58c13ac 100644 --- a/test/05Font/main.cpp +++ b/test/05Font/main.cpp @@ -12,11 +12,11 @@ FontData* data = nullptr; void onLoad() { Filesystem* fs = Filesystem::get(); - fs->mount("D:/Documents/VisualStudio2017/Projects/Jin/libjin/min/build/Debug"); + fs->mount("D:/Jin/libjin/min/build/Debug"); Buffer buffer; - fs->read("SIMYOU.TTF", &buffer); + fs->read("font.ttf", &buffer); data = FontData::createFontData((const unsigned char*)buffer.data, buffer.size); - font = Font::createFont(data, 15); + font = Font::createFont(data, 50); //canvas = Canvas::createCanvas(100, 100); } @@ -40,7 +40,10 @@ void onDraw() //Canvas::bind(canvas); if (font != nullptr) { - font->print(u8"hello, worldjqp", 0, 0); + glColor4f(1, 1, 0, 1); + //font->print(u8"ԴZΤ", 0, 0); + font->print(u8"Դ", 0, 0); + glColor4f(1, 1, 1, 1); } //Canvas::unbind(); //canvas->draw(0, 0, 2, 2, 0); |