1270 {
1271 try {
1274 if (!explicit_resolution) {
1277 }
1278
1280 window.loop();
1282 std::cerr << std::format(
"mxvk: Exception: {}\n", e.
text());
1283 return EXIT_FAILURE;
1285 std::cerr << std::format(
"mxvk: Argument Exception: {}\n", e.
text());
1286 return EXIT_FAILURE;
1287 }
1288
1289 return EXIT_SUCCESS;
1290}
Arguments proc_args(int &argc, char **argv)
Parse standard libmx2 command-line options from main()'s argv.
Exception thrown by Argz::proc() on unrecognised or malformed options.
bool hasResolutionArgument(int argc, char **argv)
constexpr int base_height
Plain data structure returned by proc_args() with all common libmx2 CLI options.
bool fullscreen
Whether fullscreen mode was requested.
bool enable_vsync
Enable FIFO present mode / v-sync (--enable-vsync).
int height
Viewport height in pixels (default: 720).
std::string path
Asset root; proc_args() defaults it to the executable directory.
int width
Viewport width in pixels (default: 1280).