mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-09 16:34:03 +00:00
New Window class, and major changes to Display
This commit is contained in:
parent
bb2d3d472d
commit
796b84c3d1
9 changed files with 389 additions and 132 deletions
|
|
@ -7,6 +7,7 @@
|
|||
package org.lwjgl.test;
|
||||
|
||||
import org.lwjgl.*;
|
||||
import org.lwjgl.opengl.BaseGL;
|
||||
|
||||
/**
|
||||
* @author Brian
|
||||
|
|
@ -43,6 +44,6 @@ public class WindowCreationTest {
|
|||
|
||||
System.out.println("Display created");
|
||||
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
}
|
||||
}
|
||||
|
|
@ -35,6 +35,7 @@ import org.lwjgl.Sys;
|
|||
import org.lwjgl.Display;
|
||||
import org.lwjgl.DisplayMode;
|
||||
import org.lwjgl.input.Controller;
|
||||
import org.lwjgl.opengl.*;
|
||||
import org.lwjgl.opengl.GL;
|
||||
import org.lwjgl.opengl.GLU;
|
||||
import org.lwjgl.vector.Vector2f;
|
||||
|
|
@ -118,7 +119,7 @@ public class ControllerCreationTest {
|
|||
|
||||
// recreate display in fullscreen mode
|
||||
System.out.print("Destroying display...");
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
System.out.println("success");
|
||||
|
||||
System.out.print("Entering fullscreen mode...");
|
||||
|
|
@ -140,7 +141,7 @@ public class ControllerCreationTest {
|
|||
System.out.print("Shutting down...");
|
||||
Controller.destroy();
|
||||
gl.destroy();
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
System.out.println("shutdown complete");
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import org.lwjgl.Sys;
|
|||
import org.lwjgl.Display;
|
||||
import org.lwjgl.DisplayMode;
|
||||
import org.lwjgl.input.Mouse;
|
||||
import org.lwjgl.opengl.*;
|
||||
import org.lwjgl.opengl.GL;
|
||||
import org.lwjgl.opengl.GLU;
|
||||
import org.lwjgl.vector.Vector2f;
|
||||
|
|
@ -118,7 +119,7 @@ public class MouseCreationTest {
|
|||
|
||||
// recreate display in fullscreen mode
|
||||
System.out.print("Destroying display...");
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
System.out.println("success");
|
||||
|
||||
System.out.print("Entering fullscreen mode...");
|
||||
|
|
@ -140,7 +141,7 @@ public class MouseCreationTest {
|
|||
System.out.print("Shutting down...");
|
||||
Mouse.destroy();
|
||||
gl.destroy();
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
System.out.println("shutdown complete");
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import org.lwjgl.Display;
|
|||
import org.lwjgl.DisplayMode;
|
||||
import org.lwjgl.input.Mouse;
|
||||
import org.lwjgl.input.Keyboard;
|
||||
import org.lwjgl.opengl.*;
|
||||
import org.lwjgl.opengl.GL;
|
||||
import org.lwjgl.opengl.GLU;
|
||||
import org.lwjgl.vector.Vector2f;
|
||||
|
|
@ -118,7 +119,7 @@ public class MouseTest {
|
|||
Mouse.destroy();
|
||||
Keyboard.destroy();
|
||||
gl.destroy();
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
}
|
||||
|
||||
private void createMouse() {
|
||||
|
|
@ -131,8 +132,8 @@ public class MouseTest {
|
|||
}
|
||||
|
||||
private void wiggleMouse() {
|
||||
while (!Display.isCloseRequested()) {
|
||||
if(Display.isMinimized()) {
|
||||
while (!BaseGL.isCloseRequested()) {
|
||||
if(BaseGL.isMinimized()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ import org.lwjgl.*;
|
|||
import org.lwjgl.opengl.*;
|
||||
import org.lwjgl.input.*;
|
||||
|
||||
import java.nio.*;
|
||||
import java.nio.*;
|
||||
|
||||
public final class Game {
|
||||
static {
|
||||
|
|
@ -188,6 +188,6 @@ public final class Game {
|
|||
Keyboard.destroy();
|
||||
Mouse.destroy();
|
||||
gl.destroy();
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -214,7 +214,7 @@ public class Grass {
|
|||
Mouse.destroy();
|
||||
Keyboard.destroy();
|
||||
gl.destroy();
|
||||
Display.destroy();
|
||||
BaseGL.destroy();
|
||||
}
|
||||
|
||||
private static float myrand() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue