Search in sources :

Example 31 with ShaderProgram

use of com.badlogic.gdx.graphics.glutils.ShaderProgram in project bdx by GoranM.

the class MaterialShader method compile.

public MaterialShader compile() {
    dispose();
    programData = new ShaderProgram(prefix + vertexShader, prefix + fragmentShader);
    if (!programData.isCompiled())
        throw new RuntimeException("Shader compilation error: " + programData.getLog());
    return this;
}
Also used : ShaderProgram(com.badlogic.gdx.graphics.glutils.ShaderProgram)

Aggregations

ShaderProgram (com.badlogic.gdx.graphics.glutils.ShaderProgram)31 Texture (com.badlogic.gdx.graphics.Texture)10 VertexAttribute (com.badlogic.gdx.graphics.VertexAttribute)9 Mesh (com.badlogic.gdx.graphics.Mesh)8 SpriteBatch (com.badlogic.gdx.graphics.g2d.SpriteBatch)7 PerspectiveCamera (com.badlogic.gdx.graphics.PerspectiveCamera)5 InputMultiplexer (com.badlogic.gdx.InputMultiplexer)3 BitmapFont (com.badlogic.gdx.graphics.g2d.BitmapFont)3 ModelInstance (com.badlogic.gdx.graphics.g3d.ModelInstance)3 GdxRuntimeException (com.badlogic.gdx.utils.GdxRuntimeException)3 OrthographicCamera (com.badlogic.gdx.graphics.OrthographicCamera)2 Pixmap (com.badlogic.gdx.graphics.Pixmap)2 TextureAtlas (com.badlogic.gdx.graphics.g2d.TextureAtlas)2 Material (com.badlogic.gdx.graphics.g3d.Material)2 ModelBatch (com.badlogic.gdx.graphics.g3d.ModelBatch)2 FirstPersonCameraController (com.badlogic.gdx.graphics.g3d.utils.FirstPersonCameraController)2 ModelBuilder (com.badlogic.gdx.graphics.g3d.utils.ModelBuilder)2 FrameBuffer (com.badlogic.gdx.graphics.glutils.FrameBuffer)2 IndexBufferObject (com.badlogic.gdx.graphics.glutils.IndexBufferObject)2 VertexBufferObject (com.badlogic.gdx.graphics.glutils.VertexBufferObject)2