Class Filter3<T>

  • Direct Known Subclasses:
    RaymarchingFilter

    public abstract class Filter3<T>
    extends java.lang.Object
    The base class for any single-pass filter.
    • Field Detail

      • inputTexture

        protected com.badlogic.gdx.graphics.Texture inputTexture
      • inputBuffer

        protected com.badlogic.gdx.graphics.glutils.FrameBuffer inputBuffer
      • outputBuffer

        protected com.badlogic.gdx.graphics.glutils.FrameBuffer outputBuffer
      • program

        protected com.badlogic.gdx.graphics.glutils.ShaderProgram program
    • Constructor Detail

      • Filter3

        public Filter3​(com.badlogic.gdx.graphics.glutils.ShaderProgram program)
    • Method Detail

      • setInput

        public T setInput​(com.badlogic.gdx.graphics.Texture input)
      • setInput

        public T setInput​(com.badlogic.gdx.graphics.glutils.FrameBuffer input)
      • setOutput

        public T setOutput​(com.badlogic.gdx.graphics.glutils.FrameBuffer output)
      • updateProgram

        public void updateProgram​(com.badlogic.gdx.graphics.glutils.ShaderProgram program)
        Caution, disposes of the current program and updates it with the new one. Run synchronously after render().
        Parameters:
        program - The new shader program.
      • dispose

        public void dispose()
      • rebind

        public abstract void rebind()
        FIXME add comment
      • setParam

        protected void setParam​(Filter3.Parameter param,
                                com.badlogic.gdx.math.Vector2 value)
      • setParam

        protected void setParam​(Filter3.Parameter param,
                                com.badlogic.gdx.math.Vector3 value)
      • setParam

        protected T setParam​(Filter3.Parameter param,
                             com.badlogic.gdx.math.Matrix3 value)
      • setParam

        protected T setParam​(Filter3.Parameter param,
                             com.badlogic.gdx.math.Matrix4 value)
      • setParamv

        protected T setParamv​(Filter3.Parameter param,
                              float[] values,
                              int offset,
                              int length)
      • setParams

        protected T setParams​(Filter3.Parameter param,
                              float value)
        Sets the parameter to the specified value for this filter. When you are finished building the batch you shall signal it by invoking endParams().
      • setParams

        protected T setParams​(Filter3.Parameter param,
                              com.badlogic.gdx.math.Vector2 value)
      • setParams

        protected T setParams​(Filter3.Parameter param,
                              com.badlogic.gdx.math.Vector3 value)
      • setParams

        protected T setParams​(Filter3.Parameter param,
                              com.badlogic.gdx.math.Matrix3 value)
      • setParams

        protected T setParams​(Filter3.Parameter param,
                              com.badlogic.gdx.math.Matrix4 value)
      • setParamsv

        protected T setParamsv​(Filter3.Parameter param,
                               float[] values,
                               int offset,
                               int length)
      • endParams

        protected void endParams()
        Should be called after any one or more setParams method calls.
      • onBeforeRender

        protected abstract void onBeforeRender()
        This method will get called just before a rendering operation occurs.
      • render

        public final void render()
      • realRender

        protected void realRender()