![]() | Ned Batchelder : Blog | Code | Text | Site dispmode » Home : Code : Windows Utils |
Created 4 May 2002, last updated 6 April 2003 My kids have a large library of computer games, some of which are quite old (as these things go). Newer games can properly detect and modify the display settings if they are particular, but some older programs just complain (sometimes after mis-detecting the settings). To simplify my kids' use of the computer, I wrote this command to change the display settings. Now I can create icons for their games which invoke batch files to call dispmode to set the display properly, and then run the game. Ah, peace! The arguments are simple: specify either the new width (in pixels) or the new depth (in bits per pixel), or both. You don't need to specify the height because that is determined by the width. If you leave out the width or depth, then it is unchanged. If you only specify a single number, it is a depth if it is less than 300, or a width if it is more than 300. Simple: $ dispmode 1400 The refresh rate of the display can also be adjusted by adding an argument with a "Hz" suffix: $ dispmode 1400 60Hz There are other options:
Want the source? Download: dispmode.cpp | |
Comments
Add a comment: