SDL_Rect *points;
char **names;
+int cur = -1;
int psize;
int stop = 0;
GetNextPoint (void)
{
static SDL_Rect rect = {0, 0, WIDTH, HEIGHT};
- static int cur = -1;
static int inc, err, thre, swap;
static int x1, y1, x2, y2;
static int x, y;
SDL_UpdateRect (slice, 0, 0, 0, 0);
scale = CairoTarget (slice);
SDL_FreeSurface (slice);
- text = TTF_RenderUTF8_Solid (font, "GNU", Yellow);
- box.w = text->w + HBORDER;
- box.h = text->h + VBORDER;
- box.x = (WIDTH - text->w - HBORDER) / 2;
- box.y = HEIGHT - (text->h + 32 + VBORDER/2);
- SDL_FillRect (scale, &box, SDL_MapRGB (scale->format, 0, 0, 0));
- box.x += HBORDER/2;
- box.y += VBORDER/2;
- box.w -= HBORDER;
- box.h -= VBORDER;
- SDL_BlitSurface (text, NULL, scale, &box);
+ if (stop)
+ {
+ text = TTF_RenderUTF8_Solid (font, names[cur], Yellow);
+ box.w = text->w + HBORDER;
+ box.h = text->h + VBORDER;
+ box.x = (WIDTH - text->w - HBORDER) / 2;
+ box.y = HEIGHT - (text->h + 32 + VBORDER/2);
+ SDL_FillRect (scale, &box, SDL_MapRGB (scale->format, 0, 0, 0));
+ box.x += HBORDER/2;
+ box.y += VBORDER/2;
+ box.w -= HBORDER;
+ box.h -= VBORDER;
+ SDL_BlitSurface (text, NULL, scale, &box);
+ SDL_FreeSurface (text);
+ }
SDL_UpdateRect (scale, 0, 0, 0, 0);
- SDL_FreeSurface (text);
return scale;
}