Class GraphicConfiguration
java.lang.Object
de.gurkenlabs.litiengine.configuration.ConfigurationGroup
de.gurkenlabs.litiengine.configuration.GraphicConfiguration
Represents the graphic configuration settings. This class extends the ConfigurationGroup to provide specific settings for graphics.
-
Nested Class Summary
Nested classes/interfaces inherited from class de.gurkenlabs.litiengine.configuration.ConfigurationGroup
ConfigurationGroup.ConfigurationChangedListener -
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if anti-aliasing is enabled.booleanChecks if color interpolation is enabled.booleanChecks if resolution scaling is enabled.Gets the current display mode.intGets the current resolution height.intGets the current resolution width.booleanChecks if frames should be reduced when not focused.booleanChecks if dynamic shadows rendering is enabled.voidsetAntiAliasing(boolean antiAliasing) Sets whether to enable anti-aliasing.voidsetColorInterpolation(boolean colorInterpolation) Sets whether to enable color interpolation.voidsetDisplayMode(DisplayMode displayMode) Sets the display mode.voidsetEnableResolutionScale(boolean enableResolutionScale) Sets whether to enable resolution scaling.voidsetGraphicQuality(Quality graphicQuality) Sets the graphic quality.voidsetReduceFramesWhenNotFocused(boolean reduceFramesWhenNotFocused) Sets whether to reduce frames when not focused.voidsetRenderDynamicShadows(boolean renderDynamicShadows) Sets whether to render dynamic shadows.voidsetResolutionHeight(int resolutionHeight) Sets the resolution height.voidsetResolutionWidth(int resolutionWidth) Sets the resolution width.Methods inherited from class de.gurkenlabs.litiengine.configuration.ConfigurationGroup
getPrefix, initializeByProperty, isDebug, onChanged, removeListener, set, setDebug, storeProperties
-
Method Details
-
getGraphicQuality
-
getResolution
-
getResolutionHeight
public int getResolutionHeight()Gets the current resolution height.- Returns:
- the resolution height.
-
getResolutionWidth
public int getResolutionWidth()Gets the current resolution width.- Returns:
- the resolution width.
-
renderDynamicShadows
public boolean renderDynamicShadows()Checks if dynamic shadows rendering is enabled.- Returns:
- true if dynamic shadows rendering is enabled, false otherwise.
-
antiAliasing
public boolean antiAliasing()Checks if anti-aliasing is enabled.- Returns:
- true if anti-aliasing is enabled, false otherwise.
-
colorInterpolation
public boolean colorInterpolation()Checks if color interpolation is enabled.- Returns:
- true if color interpolation is enabled, false otherwise.
-
getDisplayMode
-
setDisplayMode
Sets the display mode.- Parameters:
displayMode- the new display mode.
-
setGraphicQuality
Sets the graphic quality.- Parameters:
graphicQuality- the new graphic quality.
-
setRenderDynamicShadows
public void setRenderDynamicShadows(boolean renderDynamicShadows) Sets whether to render dynamic shadows.- Parameters:
renderDynamicShadows- true to enable dynamic shadows rendering, false to disable.
-
setResolutionHeight
public void setResolutionHeight(int resolutionHeight) Sets the resolution height.- Parameters:
resolutionHeight- the new resolution height.
-
setResolutionWidth
public void setResolutionWidth(int resolutionWidth) Sets the resolution width.- Parameters:
resolutionWidth- the new resolution width.
-
enableResolutionScaling
public boolean enableResolutionScaling()Checks if resolution scaling is enabled.- Returns:
- true if resolution scaling is enabled, false otherwise.
-
setEnableResolutionScale
public void setEnableResolutionScale(boolean enableResolutionScale) Sets whether to enable resolution scaling.- Parameters:
enableResolutionScale- true to enable resolution scaling, false to disable.
-
reduceFramesWhenNotFocused
public boolean reduceFramesWhenNotFocused()Checks if frames should be reduced when not focused.- Returns:
- true if frames should be reduced when not focused, false otherwise.
-
setReduceFramesWhenNotFocused
public void setReduceFramesWhenNotFocused(boolean reduceFramesWhenNotFocused) Sets whether to reduce frames when not focused.- Parameters:
reduceFramesWhenNotFocused- true to reduce frames when not focused, false to not reduce.
-
setAntiAliasing
public void setAntiAliasing(boolean antiAliasing) Sets whether to enable anti-aliasing.- Parameters:
antiAliasing- true to enable anti-aliasing, false to disable.
-
setColorInterpolation
public void setColorInterpolation(boolean colorInterpolation) Sets whether to enable color interpolation.- Parameters:
colorInterpolation- true to enable color interpolation, false to disable.
-