2015-05-12 11:15:16 +12:00
|
|
|
// Copyright 2013 Normmatt
|
|
|
|
// Licensed under GPLv2 or any later version
|
|
|
|
// Refer to the license.txt file included.
|
|
|
|
|
2015-05-04 15:32:23 -07:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "common.h"
|
|
|
|
|
|
|
|
#define BYTES_PER_PIXEL 3
|
|
|
|
#define SCREEN_WIDTH 240
|
|
|
|
#define SCREEN_HEIGHT 400
|
|
|
|
|
|
|
|
#define SCREEN_SIZE (BYTES_PER_PIXEL * SCREEN_WIDTH * SCREEN_HEIGHT)
|
|
|
|
|
|
|
|
#define RGB(r,g,b) (r<<24|b<<16|g<<8|r)
|
|
|
|
|
2016-06-07 23:15:14 -04:00
|
|
|
extern u8 *TOP_SCREEN0;
|
|
|
|
extern u8 *TOP_SCREEN1;
|
|
|
|
extern u8 *BOT_SCREEN0;
|
|
|
|
extern u8 *BOT_SCREEN1;
|
2016-03-07 23:12:22 -05:00
|
|
|
|
2016-06-07 02:30:30 -04:00
|
|
|
extern size_t current_y;
|
2015-05-04 15:32:23 -07:00
|
|
|
|
2016-06-07 23:15:14 -04:00
|
|
|
void DrawInit(void);
|
2015-05-04 15:32:23 -07:00
|
|
|
void ClearScreen(unsigned char *screen, int color);
|
2016-06-07 02:30:30 -04:00
|
|
|
void DrawCharacter(unsigned char *screen, int character, size_t x, size_t y, int color, int bgcolor);
|
|
|
|
void DrawHex(unsigned char *screen, unsigned int hex, size_t x, size_t y, int color, int bgcolor);
|
|
|
|
void DrawString(unsigned char *screen, const char *str, size_t x, size_t y, int color, int bgcolor);
|
|
|
|
void DrawStringF(size_t x, size_t y, const char *format, ...);
|
|
|
|
void DrawHexWithName(unsigned char *screen, const char *str, unsigned int hex, size_t x, size_t y, int color, int bgcolor);
|
2015-05-04 15:32:23 -07:00
|
|
|
|
|
|
|
void Debug(const char *format, ...);
|