Added display showing information about selected vertex

This commit is contained in:
2011-07-01 18:04:15 -04:00
parent d15e6590ec
commit c49fdb8169
5 changed files with 38 additions and 12 deletions

View File

@ -152,7 +152,7 @@ bool DrawUtils::transpare(SDL_Surface* surface, int r, int g, int b)
// Modified from
// http://www.parallelrealities.co.uk/tutorials/basic/tutorial7.php
void DrawUtils::draw_text(SDL_Surface* display, string text, int x, int y,
TTF_Font *font, bool center_x, bool center_y)
TTF_Font *font)
{
SDL_Rect dest;
SDL_Surface *surface;
@ -174,8 +174,8 @@ void DrawUtils::draw_text(SDL_Surface* display, string text, int x, int y,
}
/* Blit the surface */
dest.x = (center_x ? (display->w - surface->w) / 2 : x);
dest.y = (center_y ? (display->h - surface->h) / 2 : y);
dest.x = x;
dest.y = y;
dest.w = surface->w;
dest.h = surface->h;