Created
February 8, 2014 11:40
-
-
Save bitbrain/8882474 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Create a new shader manager | |
ShaderManager shaderManager = new ShaderManager(); | |
// Create shaders | |
BlurShader blurShader = new BlurShader(); | |
CRTShader crtShader = new CRTShader(); | |
// Add them to the manager in a layer-based way. At first, the blur shader is applied and so on. | |
shaderManager.add(this, blurShader, crtShader); | |
/* ... */ | |
// In the resize method: | |
shaderManager.resize(width, height); | |
// In the render method: | |
shaderManager.updateAndRender(batch, delta); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment