public class AndroidApplicationConfiguration
extends java.lang.Object
AndroidApplication
. Allows you to disable the use of the accelerometer to save
battery among other things.Modifier and Type | Field and Description |
---|---|
int |
a
number of bits per color channel
|
int |
b
number of bits per color channel
|
int |
depth
number of bits for depth and stencil buffer
|
boolean |
disableAudio
whether to disable Android audio support.
|
int |
g
number of bits per color channel
|
boolean |
getTouchEventsForLiveWallpaper
if the app is a livewallpaper, whether it should get full touch events
|
boolean |
hideStatusBar
hide status bar buttons on Android 4.x and higher (API 14+).
|
int |
maxNetThreads
The maximum number of threads to use for network requests.
|
int |
maxSimultaneousSounds
the maximum number of
Sound instances that can be played simultaneously, sets the corresponding SoundPool
constructor argument. |
int |
numSamples
number of samples for CSAA/MSAA, 2 is a good value
|
int |
r
number of bits per color channel
|
ResolutionStrategy |
resolutionStrategy
the
ResolutionStrategy . |
int |
sensorDelay
The requested sensor sampling rate in microseconds or one of the
SENSOR_DELAY_* constants in SensorManager . |
int |
stencil
number of bits for depth and stencil buffer
|
int |
touchSleepTime
the time in milliseconds to sleep after each event in the touch handler, set this to 16ms to get rid of touch flooding on
pre Android 2.0 devices.
|
boolean |
useAccelerometer
whether to use the accelerometer.
|
boolean |
useCompass
Whether to use the compass.
|
boolean |
useGL30
Deprecated.
this option is currently experimental and not yet fully supported, expect issues.
|
boolean |
useGyroscope
whether to use the gyroscope.
|
boolean |
useImmersiveMode
set this to true to enable Android 4.4 KitKat's 'Immersive mode'
|
boolean |
useRotationVectorSensor
Whether to use Android's rotation vector software sensor, which provides cleaner data than that of
useCompass for
Input.getRotationMatrix(float[]) , Input.getAzimuth() , Input.getPitch() , and Input.getRoll() . |
boolean |
useWakelock
whether to keep the screen on and at full brightness or not while running the application.
|
Constructor and Description |
---|
AndroidApplicationConfiguration() |
public int r
public int g
public int b
public int a
public int depth
public int stencil
public int numSamples
public boolean useAccelerometer
public boolean useGyroscope
public boolean useCompass
Input.getRotationMatrix(float[])
, Input.getAzimuth()
,
Input.getPitch()
, and Input.getRoll()
if useAccelerometer
is also true.
If useRotationVectorSensor
is true and the rotation vector sensor is available, the compass will not be used.
Default: true
public boolean useRotationVectorSensor
useCompass
for
Input.getRotationMatrix(float[])
, Input.getAzimuth()
, Input.getPitch()
, and Input.getRoll()
.
The rotation vector sensor uses a combination of physical sensors, and it pre-filters and smoothes the data. If true,
useAccelerometer
is not required to enable rotation data.
If true and the rotation vector sensor is available, the compass will not be used, regardless of useCompass
.
Default: false
public int sensorDelay
SENSOR_DELAY_*
constants in SensorManager
.
Default: SensorManager#SENSOR_DELAY_GAME
(20 ms updates).
public int touchSleepTime
public boolean useWakelock
public boolean hideStatusBar
public boolean disableAudio
public int maxSimultaneousSounds
Sound
instances that can be played simultaneously, sets the corresponding SoundPool
constructor argument.public ResolutionStrategy resolutionStrategy
ResolutionStrategy
. default: FillResolutionStrategy
public boolean getTouchEventsForLiveWallpaper
public boolean useImmersiveMode
@Deprecated public boolean useGL30
Gdx.gl30
can be used to access its functionality. Requires at least Android 4.3 (API level 18).public int maxNetThreads
Integer.MAX_VALUE
.