project.android.imageprocessing.filter
Class MultiTextureFilter
java.lang.Object
project.android.imageprocessing.GLRenderer
project.android.imageprocessing.input.GLTextureOutputRenderer
project.android.imageprocessing.filter.BasicFilter
project.android.imageprocessing.filter.MultiTextureFilter
- All Implemented Interfaces:
- GLTextureInputRenderer
public abstract class MultiTextureFilter
- extends BasicFilter
A multiple filter renderer extension of the BasicFilter.
This class allows for a filter that contains multiple filters to create the output.
This class can be used as the base for a filter which is made up of multiple filters.
By itself, this class is not useful because it's fragment shader only uses one texture.
To take advantage of the multiple texture inputs, the getFragmentShader() method should be
override to return a more useful fragment shader. This class supports a maximum of 10 filter
endpoints inside of it.
- Author:
- Chris Batt
Constructor Summary |
MultiTextureFilter(int numOfEndpoints)
Creates a MultiInputFilter with any number of initial filters or filter graphs that produce a
set number of textures which can be used by this filter. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MultiTextureFilter
public MultiTextureFilter(int numOfEndpoints)
- Creates a MultiInputFilter with any number of initial filters or filter graphs that produce a
set number of textures which can be used by this filter.
- Parameters:
numOfEndpoints
- The number of endpoints of this filter. For example, if the fragment shader of this filter
requires three input textures, then this would be set to three; however, this does not mean
that there can only be three initial filters.
newTextureReady
public void newTextureReady(int texture,
GLTextureOutputRenderer source)
- Description copied from interface:
GLTextureInputRenderer
- Signals that a new texture is available and the image should be reprocessed.
- Specified by:
newTextureReady
in interface GLTextureInputRenderer
- Overrides:
newTextureReady
in class BasicFilter
- Parameters:
texture
- The texture id to be used as input.source
- The GLTextureOutputRenderer which produced the texture.