From ea11a9410cb478a4afa2aee2f997210592e88bfe Mon Sep 17 00:00:00 2001 From: rexim Date: Mon, 30 Dec 2019 03:02:51 +0700 Subject: [PATCH] Add RENDERER_CONFIG --- src/config.h | 3 +++ src/main.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/config.h b/src/config.h index 7a964391..b062ebca 100644 --- a/src/config.h +++ b/src/config.h @@ -28,4 +28,7 @@ #define VERSION "2" +// #define RENDERER_CONFIG SDL_RENDERER_SOFTWARE +#define RENDERER_CONFIG (SDL_RENDERER_ACCELERATED | SDL_RENDERER_PRESENTVSYNC) + #endif // CONFIG_H_ diff --git a/src/main.c b/src/main.c index c89edc09..e4e851e6 100644 --- a/src/main.c +++ b/src/main.c @@ -132,7 +132,7 @@ int main(int argc, char *argv[]) SDL_Renderer *const renderer = PUSH_LT( lt, - SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED | SDL_RENDERER_PRESENTVSYNC), + SDL_CreateRenderer(window, -1, RENDERER_CONFIG), SDL_DestroyRenderer); if (renderer == NULL) { log_fail("Could not create SDL renderer: %s\n", SDL_GetError()); -- 2.44.0