SDL: Fix command line graphics arguments

This commit is contained in:
Jeffrey Pfau 2014-11-09 15:56:09 -08:00
parent 2d37f8cd60
commit e10d28918d
1 changed files with 2 additions and 2 deletions

View File

@ -53,8 +53,6 @@ int main(int argc, char** argv) {
struct SubParser subparser; struct SubParser subparser;
GBAConfigMap(&config, &opts);
initParserForGraphics(&subparser, &graphicsOpts); initParserForGraphics(&subparser, &graphicsOpts);
if (!parseArguments(&args, &config, argc, argv, &subparser)) { if (!parseArguments(&args, &config, argc, argv, &subparser)) {
usage(argv[0], subparser.usage); usage(argv[0], subparser.usage);
@ -64,6 +62,8 @@ int main(int argc, char** argv) {
return 1; return 1;
} }
GBAConfigMap(&config, &opts);
renderer.viewportWidth = opts.width; renderer.viewportWidth = opts.width;
renderer.viewportHeight = opts.height; renderer.viewportHeight = opts.height;
#if SDL_VERSION_ATLEAST(2, 0, 0) #if SDL_VERSION_ATLEAST(2, 0, 0)