|
|
@ -5,14 +5,17 @@ struct gui_resource_t { |
|
|
|
TTF_Font *font_big, *font_small; |
|
|
|
}; |
|
|
|
|
|
|
|
/* ouvre la fenêtre */ |
|
|
|
struct gui_resource_t display_start(); |
|
|
|
|
|
|
|
SDL_Event display_until_event(const struct gui_resource_t *res); |
|
|
|
/* ferme la fenêtre */ |
|
|
|
void display_close(struct gui_resource_t *res); |
|
|
|
|
|
|
|
/* simple rendu interne du plateau, il faut SDL_Flip() pour l'afficher */ |
|
|
|
void display_render_board(const struct gui_resource_t *res, const struct game_state_t *gamestate, enum hole_t currentplayer); |
|
|
|
|
|
|
|
|
|
|
|
/* les fonctions display_ani* retournent 1 si l'utilisateur ferme l'application, sinon 0 */ |
|
|
|
/* les fonctions suivantes retournent 1 si l'utilisateur ferme l'application, sinon 0 */ |
|
|
|
|
|
|
|
int display_animsg(const struct gui_resource_t *res, const struct game_state_t *gamestate, enum hole_t currentplayer, const char *msg, uint32_t duration); |
|
|
|
|
|
|
@ -21,5 +24,3 @@ int display_anirotate_board(const struct gui_resource_t *res, const struct game_ |
|
|
|
int display_animove_pawn(const struct gui_resource_t *res, struct game_state_t gamestate, enum hole_t currentplayer, int startpos, int endpos); |
|
|
|
|
|
|
|
int display_usermove_pawn(const struct gui_resource_t *res, const struct game_state_t *gamestate, enum hole_t currentplayer, struct move_t *move, int *moremoves); |
|
|
|
|
|
|
|
void display_close(struct gui_resource_t *res); |