From: rexim Date: Sun, 29 Dec 2019 20:02:51 +0000 (+0700) Subject: Add RENDERER_CONFIG X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=ea11a9410cb478a4afa2aee2f997210592e88bfe;p=nothing.git Add RENDERER_CONFIG --- 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());