# HG changeset patch # User Mike Pavone # Date 1373525529 25200 # Node ID ed4d0017c041e224d82bc337bf2fe3c001018b1b # Parent 18cde14e8c102a45f1319527a63a54eaca355822 Read default render width from config file diff -r 18cde14e8c10 -r ed4d0017c041 blastem.c --- a/blastem.c Wed Jul 10 23:47:48 2013 -0700 +++ b/blastem.c Wed Jul 10 23:52:09 2013 -0700 @@ -1953,7 +1953,15 @@ } } update_title(); - width = width < 320 ? 640 : width; + int def_width = 0; + char *config_width = tern_find_ptr(config, "videowidth"); + if (config_width) { + def_width = atoi(config_width); + } + if (!def_width) { + def_width = 640; + } + width = width < 320 ? def_width : width; height = height < 240 ? (width/320) * 240 : height; uint32_t fps = 60; if (version_reg & 0x40) {