Changeset - r23565:dd2703eca0f6
[Not reviewed]
master
0 1 0
Niels Martin Hansen - 6 years ago 2019-03-30 07:46:21
nielsm@indvikleren.dk
Change: [SDL] Do not offer video smaller than 640x480
1 file changed with 2 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/video/sdl_v.cpp
Show inline comments
 
@@ -223,6 +223,7 @@ static void GetVideoModes()
 
		for (int i = 0; modes[i]; i++) {
 
			uint w = modes[i]->w;
 
			uint h = modes[i]->h;
 
			if (w < 640 || h < 480) continue; // reject too small resolutions
 
			int j;
 
			for (j = 0; j < n; j++) {
 
				if (_resolutions[j].width == w && _resolutions[j].height == h) break;
 
@@ -234,6 +235,7 @@ static void GetVideoModes()
 
				if (++n == lengthof(_resolutions)) break;
 
			}
 
		}
 
		if (n == 0) usererror("No usable screen resolutions found!\n");
 
		_num_resolutions = n;
 
		SortResolutions(_num_resolutions);
 
	}
0 comments (0 inline, 0 general)