2013-04-18 06:29:41 +03:00
|
|
|
// Copyright 2013 Dolphin Emulator Project
|
|
|
|
// Licensed under GPLv2
|
|
|
|
// Refer to the license.txt file included.
|
2013-03-26 01:05:46 +02:00
|
|
|
|
2014-02-10 20:54:46 +02:00
|
|
|
#pragma once
|
2013-03-26 01:05:46 +02:00
|
|
|
|
2013-04-14 06:54:02 +03:00
|
|
|
class RasterFont
|
|
|
|
{
|
2013-03-26 01:05:46 +02:00
|
|
|
public:
|
2013-04-14 06:54:02 +03:00
|
|
|
RasterFont();
|
|
|
|
~RasterFont(void);
|
|
|
|
static int debug;
|
|
|
|
|
|
|
|
// some useful constants
|
2014-02-09 23:03:16 +02:00
|
|
|
enum {char_width = 10};
|
|
|
|
enum {char_height = 15};
|
2013-04-14 06:54:02 +03:00
|
|
|
|
|
|
|
// and the happy helper functions
|
|
|
|
void printString(const char *s, double x, double y, double z=0.0);
|
|
|
|
void printCenteredString(const char *s, double y, int screen_width, double z=0.0);
|
2013-03-26 01:05:46 +02:00
|
|
|
|
|
|
|
void printMultilineText(const char *text, double x, double y, double z, int bbWidth, int bbHeight);
|
|
|
|
private:
|
2013-04-14 06:54:02 +03:00
|
|
|
int fontOffset;
|
|
|
|
char *temp_buffer;
|
2013-03-26 01:05:46 +02:00
|
|
|
enum {TEMP_BUFFER_SIZE = 64 * 1024};
|
|
|
|
};
|