getting rid of the temp displaymode
This commit is contained in:
parent
4e5f69b9a0
commit
57b29d7e91
|
@ -202,12 +202,12 @@ public class DisplayContainer implements ErrorDumpable, KeyListener, MouseListen
|
||||||
width = height = -1;
|
width = height = -1;
|
||||||
Input.disableControllers();
|
Input.disableControllers();
|
||||||
Display.setTitle("opsu!dance");
|
Display.setTitle("opsu!dance");
|
||||||
// temp displaymode to not flash the screen with a 1ms black window
|
Options.setDisplayMode(this);
|
||||||
Display.setDisplayMode(new DisplayMode(100, 100));
|
|
||||||
Display.create();
|
Display.create();
|
||||||
GLHelper.setIcons(new String[] { "icon16.png", "icon32.png" });
|
GLHelper.setIcons(new String[] { "icon16.png", "icon32.png" });
|
||||||
Options.setDisplayMode(this);
|
initGL();
|
||||||
sout("GL ready");
|
sout("GL ready");
|
||||||
|
eventBus.post(new ResolutionChangedEvent(this.width, this.height));
|
||||||
glVersion = GL11.glGetString(GL11.GL_VERSION);
|
glVersion = GL11.glGetString(GL11.GL_VERSION);
|
||||||
glVendor = GL11.glGetString(GL11.GL_VENDOR);
|
glVendor = GL11.glGetString(GL11.GL_VENDOR);
|
||||||
}
|
}
|
||||||
|
@ -242,9 +242,11 @@ public class DisplayContainer implements ErrorDumpable, KeyListener, MouseListen
|
||||||
Display.setDisplayMode(displayMode);
|
Display.setDisplayMode(displayMode);
|
||||||
Display.setFullscreen(fullscreen);
|
Display.setFullscreen(fullscreen);
|
||||||
|
|
||||||
initGL();
|
if (Display.isCreated()) {
|
||||||
|
initGL();
|
||||||
|
|
||||||
eventBus.post(new ResolutionChangedEvent(this.width, this.height));
|
eventBus.post(new ResolutionChangedEvent(this.width, this.height));
|
||||||
|
}
|
||||||
|
|
||||||
if (displayMode.getBitsPerPixel() == 16) {
|
if (displayMode.getBitsPerPixel() == 16) {
|
||||||
InternalTextureLoader.get().set16BitMode();
|
InternalTextureLoader.get().set16BitMode();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user