Class LevelsFilter
java.lang.Object
gaiasky.render.postprocess.filters.Filter<LevelsFilter>
gaiasky.render.postprocess.filters.LevelsFilter
- All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class Filter
Filter.Parameter -
Field Summary
Fields inherited from class Filter
defines, fragmentShaderName, inputBuffer, inputTexture, outputBuffer, program, quad, u_texture0, u_texture1, u_texture2, u_texture3, vertexShaderNameModifier and TypeFieldDescriptionprotected Stringprotected Stringprotected com.badlogic.gdx.graphics.glutils.FrameBufferprotected com.badlogic.gdx.graphics.Textureprotected com.badlogic.gdx.graphics.glutils.FrameBufferprotected com.badlogic.gdx.graphics.glutils.ShaderProgramprotected static final FullscreenQuadprotected static final intprotected static final intprotected static final intprotected static final intprotected String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidvoidvoidvoidbooleanprotected voidThis method will get called just before a rendering operation occurs.voidrebind()voidsetAvgMaxLuma(float avgLuma, float maxLuma) voidsetBrightness(float brightness) Sets the brightness levelvoidsetContrast(float contrast) Sets the contrast levelvoidsetExposure(float exposure) Sets the exposure tone mapping valuevoidsetGamma(float gamma) Sets the gamma correction valuevoidsetHue(float hue) Sets the huevoidsetSaturation(float saturation) Sets the saturationMethods inherited from class Filter
dispose, endParams, realRender, render, setInput, setInput, setOutput, setParam, setParam, setParam, setParam, setParam, setParam, setParam, setParam, setParam, setParams, setParams, setParams, setParams, setParams, setParams, setParams, setParams, setParams, setParamsv, setParamv, updateProgram, updateProgramModifier and TypeMethodDescriptionvoiddispose()protected voidShould be called after any one or more setParams method calls.protected voidfinal voidrender()setInput(com.badlogic.gdx.graphics.glutils.FrameBuffer input) setInput(com.badlogic.gdx.graphics.Texture input) setOutput(com.badlogic.gdx.graphics.glutils.FrameBuffer output) protected voidsetParam(Filter.Parameter param, boolean value) protected voidsetParam(Filter.Parameter param, float value) protected voidsetParam(Filter.Parameter param, int value) protected voidsetParam(Filter.Parameter param, com.badlogic.gdx.graphics.Color value) protected LevelsFiltersetParam(Filter.Parameter param, com.badlogic.gdx.math.Matrix3 value) protected LevelsFiltersetParam(Filter.Parameter param, com.badlogic.gdx.math.Matrix4 value) protected voidsetParam(Filter.Parameter param, com.badlogic.gdx.math.Vector2 value) protected voidsetParam(Filter.Parameter param, com.badlogic.gdx.math.Vector3 value) protected voidsetParam(Filter.Parameter param, com.badlogic.gdx.math.Vector4 value) protected LevelsFiltersetParams(Filter.Parameter param, boolean value) protected LevelsFiltersetParams(Filter.Parameter param, float value) Sets the parameter to the specified value for this filter.protected LevelsFiltersetParams(Filter.Parameter param, int value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.graphics.Color value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.math.Matrix3 value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.math.Matrix4 value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.math.Vector2 value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.math.Vector3 value) protected LevelsFiltersetParams(Filter.Parameter param, com.badlogic.gdx.math.Vector4 value) protected LevelsFiltersetParamsv(Filter.Parameter param, float[] values, int offset, int length) protected LevelsFiltersetParamv(Filter.Parameter param, float[] values, int offset, int length) voidDisposes the current shader, reloads it from disk and re-compiles it.voidupdateProgram(com.badlogic.gdx.graphics.glutils.ShaderProgram program) Caution, disposes of the current program and updates it with the new one.
-
Constructor Details
-
LevelsFilter
public LevelsFilter()
-
-
Method Details
-
setContrast
public void setContrast(float contrast) Sets the contrast level- Parameters:
contrast- The contrast value in [0..2]
-
setBrightness
public void setBrightness(float brightness) Sets the brightness level- Parameters:
brightness- The brightness value in [-1..1]
-
setSaturation
public void setSaturation(float saturation) Sets the saturation- Parameters:
saturation- The saturation level in [0..2]
-
setHue
public void setHue(float hue) Sets the hue- Parameters:
hue- The hue level in [0..2]
-
setGamma
public void setGamma(float gamma) Sets the gamma correction value- Parameters:
gamma- Gamma value in [0..3]
-
setExposure
public void setExposure(float exposure) Sets the exposure tone mapping value- Parameters:
exposure- Exposure value in [0..n]
-
setAvgMaxLuma
public void setAvgMaxLuma(float avgLuma, float maxLuma) -
enableToneMappingExposure
public void enableToneMappingExposure() -
enableToneMappingAuto
public void enableToneMappingAuto() -
enableToneMappingACES
public void enableToneMappingACES() -
enableToneMappingUncharted
public void enableToneMappingUncharted() -
enableToneMappingFilmic
public void enableToneMappingFilmic() -
isToneMappingAuto
public boolean isToneMappingAuto() -
disableToneMapping
public void disableToneMapping() -
rebind
public void rebind()- Specified by:
rebindin classFilter<LevelsFilter>
-
onBeforeRender
protected void onBeforeRender()Description copied from class:FilterThis method will get called just before a rendering operation occurs.- Specified by:
onBeforeRenderin classFilter<LevelsFilter>
-