summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/i_video.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/i_video.c b/src/i_video.c
index f94b7192..98eb41ac 100644
--- a/src/i_video.c
+++ b/src/i_video.c
@@ -1201,6 +1201,7 @@ static void CheckCommandLine(void)
//!
// @category video
+ // @arg <x>
//
// Specify the screen width, in pixels.
//
@@ -1214,6 +1215,7 @@ static void CheckCommandLine(void)
//!
// @category video
+ // @arg <y>
//
// Specify the screen height, in pixels.
//
@@ -1227,6 +1229,26 @@ static void CheckCommandLine(void)
//!
// @category video
+ // @arg <WxY>
+ //
+ // Specify the screen mode (when running fullscreen) or the window
+ // dimensions (when running in windowed mode).
+
+ i = M_CheckParm("-geometry");
+
+ if (i > 0)
+ {
+ int w, h;
+
+ if (sscanf(myargv[i + 1], "%ix%i", &w, &h) == 2)
+ {
+ screen_width = w;
+ screen_height = h;
+ }
+ }
+
+ //!
+ // @category video
//
// Don't scale up the screen.
//