Search in sources :

Example 1 with Shader

use of org.terasology.engine.rendering.assets.shader.Shader in project Terasology by MovingBlocks.

the class ShaderManagerLwjgl method recompileAllShaders.

@Override
public void recompileAllShaders() {
    AssetManager assetManager = CoreRegistry.get(AssetManager.class);
    assetManager.getLoadedAssets(Shader.class).forEach(Shader::recompile);
    assetManager.getLoadedAssets(Material.class).forEach(Material::recompile);
    activeMaterial = null;
}
Also used : AssetManager(org.terasology.gestalt.assets.management.AssetManager) GLSLMaterial(org.terasology.engine.rendering.opengl.GLSLMaterial) Material(org.terasology.engine.rendering.assets.material.Material) Shader(org.terasology.engine.rendering.assets.shader.Shader)

Aggregations

Material (org.terasology.engine.rendering.assets.material.Material)1 Shader (org.terasology.engine.rendering.assets.shader.Shader)1 GLSLMaterial (org.terasology.engine.rendering.opengl.GLSLMaterial)1 AssetManager (org.terasology.gestalt.assets.management.AssetManager)1