From 291e4c73d6b4c4717b69d44f97dd9547c20470cd Mon Sep 17 00:00:00 2001 From: Sebastian Krzyszkowiak Date: Sun, 3 Jun 2018 03:39:28 +0200 Subject: [PATCH] use al_reset_clipping_rectangle for clarity --- src/internal.c | 2 +- src/utils.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/internal.c b/src/internal.c index 8849348..cd16b29 100644 --- a/src/internal.c +++ b/src/internal.c @@ -437,7 +437,7 @@ SYMBOL_INTERNAL void RemoveTimeline(struct Game* game, struct Timeline* timeline SYMBOL_INTERNAL void ClearScreen(struct Game* game) { al_set_target_backbuffer(game->display); - al_set_clipping_rectangle(0, 0, al_get_display_width(game->display), al_get_display_height(game->display)); + al_reset_clipping_rectangle(); al_clear_to_color(al_map_rgb(0, 0, 0)); al_clear_depth_buffer(1.0); al_set_clipping_rectangle(game->_priv.clip_rect.x, game->_priv.clip_rect.y, game->_priv.clip_rect.w, game->_priv.clip_rect.h); diff --git a/src/utils.c b/src/utils.c index 939ecdd..94fb740 100644 --- a/src/utils.c +++ b/src/utils.c @@ -468,7 +468,7 @@ SYMBOL_EXPORT void SetupViewport(struct Game* game, struct Viewport config) { al_set_target_backbuffer(game->display); al_identity_transform(&game->projection); al_use_transform(&game->projection); - al_set_clipping_rectangle(0, 0, al_get_display_width(game->display), al_get_display_height(game->display)); + al_reset_clipping_rectangle(); float resolution = al_get_display_height(game->display) / (float)game->viewport.height; if (al_get_display_width(game->display) / (float)game->viewport.width < resolution) {