| Modifier and Type | Field and Description |
|---|---|
| pack-priv Canvas | display_parent
The Canvas where the LWJGL Display is added |
| private JFrame | |
| pack-priv Thread | gameThread
Thread which runs the main game loop |
| private final JPanel | |
| private final JPanel | |
| pack-priv boolean | running
is the game loop running |
| private final JTextPane |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| protected void | |
| protected void | |
| private void | |
| public static void | |
| public void | startLWJGL()
Once the Canvas is created its add notify method will call this method to start the LWJGL Display and game loop in another thread. |
| private void |
| display_parent | back to summary |
|---|---|
| pack-priv Canvas display_parent The Canvas where the LWJGL Display is added | |
| frame | back to summary |
|---|---|
| private JFrame frame | |
| gameThread | back to summary |
|---|---|
| pack-priv Thread gameThread Thread which runs the main game loop | |
| panel1 | back to summary |
|---|---|
| private final JPanel panel1 | |
| panel2 | back to summary |
|---|---|
| private final JPanel panel2 | |
| running | back to summary |
|---|---|
| pack-priv boolean running is the game loop running | |
| textPane | back to summary |
|---|---|
| private final JTextPane textPane | |
| SwingFocusTest | back to summary |
|---|---|
| public SwingFocusTest() | |
| execute | back to summary |
|---|---|
| private void execute() | |
| gameLoop | back to summary |
|---|---|
| protected void gameLoop() | |
| initGL | back to summary |
|---|---|
| protected void initGL() | |
| initialize | back to summary |
|---|---|
| private void initialize() | |
| main | back to summary |
|---|---|
| public static void main(String[] args) | |
| startLWJGL | back to summary |
|---|---|
| public void startLWJGL() Once the Canvas is created its add notify method will call this method to start the LWJGL Display and game loop in another thread. | |
| stopLWJGL | back to summary |
|---|---|
| private void stopLWJGL() Tell game loop to stop running, after which the LWJGL Display will be destoryed. The main thread will wait for the Display.destroy() to complete | |