Windows: Don't use a dummy window (HDC) when finding a pixel format but use the actual window directly. This will avoid cases where the pixel format index for the dummy window's HDC wasn't valid for the actual window's HDC. It also avoid unnecessary complexity.

Fix FullScreenWindowedTest to use the Display's current BPP to avoid 24/16 bpp weirdness
This commit is contained in:
Elias Naur 2006-10-11 13:48:48 +00:00
parent 1b1b9c5416
commit dedfaea500
6 changed files with 62 additions and 69 deletions

View file

@ -80,7 +80,7 @@ public class FullScreenWindowedTest {
private void initialize() {
try {
//find displaymode
mode = findDisplayMode(800, 600, 16);
mode = findDisplayMode(800, 600, Display.getDisplayMode().getBitsPerPixel());
// start of in windowed mode
Display.create();
glInit();