public class LwjglApplicationConfiguration
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
protected static class |
LwjglApplicationConfiguration.LwjglApplicationConfigurationDisplayMode |
Modifier and Type | Field and Description |
---|---|
int |
a
number of bits per color channel
|
boolean |
allowSoftwareMode
Allows software OpenGL rendering if hardware acceleration was not available.
|
int |
audioDeviceBufferCount
the audio device buffer count
|
int |
audioDeviceBufferSize
the audio device buffer size in samples
|
int |
audioDeviceSimultaneousSources
the maximum number of sources that can be played simultaneously
|
int |
b
number of bits per color channel
|
int |
backgroundFPS
Target framerate when the window is not in the foreground.
|
int |
depth
number of bits for depth and stencil buffer
|
static boolean |
disableAudio
If true, OpenAL will not be used.
|
boolean |
forceExit
whether to call System.exit() on tear-down.
|
int |
foregroundFPS
Target framerate when the window is in the foreground.
|
boolean |
fullscreen
fullscreen
|
int |
g
number of bits per color channel
|
int |
gles30ContextMajorVersion
The OpenGL context major version (the part in front of the decimal point) used to emulate OpenGL ES 3.0, when the version
is not supported it will fall back to OpenGL ES 2.0 emulation.
|
int |
gles30ContextMinorVersion
The OpenGL context major version (the part after the decimal point) used to emulate OpenGL ES 3.0, when the version is not
supported it will fall back to OpenGL ES 2.0 emulation.
|
int |
height
width & height of application window
|
Color |
initialBackgroundColor |
int |
maxNetThreads
The maximum number of threads to use for network requests.
|
int |
overrideDensity
used to emulate screen densities
|
boolean |
pauseWhenBackground
LifecycleListener.pause() (but continue rendering) when the window is not minimized and not the foreground window. |
boolean |
pauseWhenMinimized
LifecycleListener.pause() and don't render when the window is minimized. |
java.lang.String |
preferencesDirectory
Preferences directory on the desktop.
|
Files.FileType |
preferencesFileType
Preferences file type on the desktop.
|
int |
r
number of bits per color channel
|
boolean |
resizable
whether the window is resizable
|
int |
samples
number of samples for MSAA
|
LwjglGraphics.SetDisplayModeCallback |
setDisplayModeCallback
Callback used when trying to create a display, can handle failures, default value is null (disabled)
|
int |
stencil
number of bits for depth and stencil buffer
|
java.lang.String |
title
title of application
|
boolean |
undecorated
whether the window is undecorated
|
boolean |
useGL30
whether to attempt use OpenGL ES 3.0.
|
boolean |
useHDPI
enable HDPI mode on Mac OS X
|
boolean |
vSyncEnabled
whether to enable vsync, can be changed at runtime via
Graphics.setVSync(boolean) |
int |
width
width & height of application window
|
int |
x
x & y of application window, -1 for center
|
int |
y
x & y of application window, -1 for center
|
Constructor and Description |
---|
LwjglApplicationConfiguration() |
Modifier and Type | Method and Description |
---|---|
void |
addIcon(java.lang.String path,
Files.FileType fileType)
Adds a window icon.
|
static Graphics.DisplayMode |
getDesktopDisplayMode() |
static Graphics.DisplayMode[] |
getDisplayModes() |
void |
setFromDisplayMode(Graphics.DisplayMode mode)
Sets the r, g, b and a bits per channel based on the given
Graphics.DisplayMode and sets the fullscreen flag to true. |
public static boolean disableAudio
Application.getAudio()
returns null and the gdx-openal.jar and OpenAL
natives are not needed.public int maxNetThreads
Integer.MAX_VALUE
.public boolean useGL30
public int gles30ContextMajorVersion
useGL30
is true. OpenGL is fully compatible with OpenGL ES 3.0 since version 4.3, setting the context version to a
lower value might cause some features not to function properly. OSX requires 3.2 though.public int gles30ContextMinorVersion
useGL30
is true. OpenGL is fully compatible with OpenGL ES 3.0 since version 4.3, setting the context version to a lower value might
cause some features not to function properly. OSX requires 3.2 though.public int r
public int g
public int b
public int a
public int depth
public int stencil
public int samples
public int width
public int height
public int x
public int y
public boolean fullscreen
public int overrideDensity
public boolean vSyncEnabled
Graphics.setVSync(boolean)
public java.lang.String title
public boolean forceExit
public boolean resizable
public boolean undecorated
public int audioDeviceSimultaneousSources
public int audioDeviceBufferSize
public int audioDeviceBufferCount
public Color initialBackgroundColor
public int foregroundFPS
public int backgroundFPS
public boolean pauseWhenMinimized
LifecycleListener.pause()
and don't render when the window is minimized.public boolean pauseWhenBackground
LifecycleListener.pause()
(but continue rendering) when the window is not minimized and not the foreground window.
To stop rendering when not the foreground window, use backgroundFPS -1.public boolean allowSoftwareMode
LwjglGraphics#isSoftwareMode()
public java.lang.String preferencesDirectory
public Files.FileType preferencesFileType
public LwjglGraphics.SetDisplayModeCallback setDisplayModeCallback
public boolean useHDPI
public void addIcon(java.lang.String path, Files.FileType fileType)
public void setFromDisplayMode(Graphics.DisplayMode mode)
Graphics.DisplayMode
and sets the fullscreen flag to true.mode
- public static Graphics.DisplayMode getDesktopDisplayMode()
public static Graphics.DisplayMode[] getDisplayModes()