|
|
@ -19,6 +19,8 @@ namespace DFHack {
|
|
|
|
static bool g_loaded = false;
|
|
|
|
static bool g_loaded = false;
|
|
|
|
static long g_num_dfhack_textures = 0;
|
|
|
|
static long g_num_dfhack_textures = 0;
|
|
|
|
static long g_dfhack_logo_texpos_start = -1;
|
|
|
|
static long g_dfhack_logo_texpos_start = -1;
|
|
|
|
|
|
|
|
static long g_green_pin_texpos_start = -1;
|
|
|
|
|
|
|
|
static long g_red_pin_texpos_start = -1;
|
|
|
|
|
|
|
|
|
|
|
|
// Converts an arbitrary Surface to something like the display format
|
|
|
|
// Converts an arbitrary Surface to something like the display format
|
|
|
|
// (32-bit RGBA), and converts magenta to transparency if convert_magenta is set
|
|
|
|
// (32-bit RGBA), and converts magenta to transparency if convert_magenta is set
|
|
|
@ -111,6 +113,10 @@ void Textures::init(color_ostream &out) {
|
|
|
|
|
|
|
|
|
|
|
|
g_num_dfhack_textures = load_textures(out, "hack/data/art/dfhack.png",
|
|
|
|
g_num_dfhack_textures = load_textures(out, "hack/data/art/dfhack.png",
|
|
|
|
&g_dfhack_logo_texpos_start);
|
|
|
|
&g_dfhack_logo_texpos_start);
|
|
|
|
|
|
|
|
g_num_dfhack_textures += load_textures(out, "hack/data/art/green-pin.png",
|
|
|
|
|
|
|
|
&g_green_pin_texpos_start);
|
|
|
|
|
|
|
|
g_num_dfhack_textures += load_textures(out, "hack/data/art/red-pin.png",
|
|
|
|
|
|
|
|
&g_red_pin_texpos_start);
|
|
|
|
|
|
|
|
|
|
|
|
DEBUG(textures,out).print("loaded %ld textures\n", g_num_dfhack_textures);
|
|
|
|
DEBUG(textures,out).print("loaded %ld textures\n", g_num_dfhack_textures);
|
|
|
|
|
|
|
|
|
|
|
@ -146,3 +152,11 @@ void Textures::cleanup() {
|
|
|
|
long Textures::getDfhackLogoTexposStart() {
|
|
|
|
long Textures::getDfhackLogoTexposStart() {
|
|
|
|
return g_dfhack_logo_texpos_start;
|
|
|
|
return g_dfhack_logo_texpos_start;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
long Textures::getGreenPinTexposStart() {
|
|
|
|
|
|
|
|
return g_green_pin_texpos_start;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
long Textures::getRedPinTexposStart() {
|
|
|
|
|
|
|
|
return g_red_pin_texpos_start;
|
|
|
|
|
|
|
|
}
|
|
|
|