Search in sources :

Example 1 with ShaderEffectWrapper

use of org.bleachhack.util.shader.ShaderEffectWrapper in project BleachHack by BleachDrinker420.

the class BlockHighlight method onEnable.

@Override
public void onEnable(boolean inWorld) {
    super.onEnable(inWorld);
    try {
        shader = new ShaderEffectWrapper(new ShaderEffect(mc.getTextureManager(), mc.getResourceManager(), mc.getFramebuffer(), new Identifier("bleachhack", "shaders/post/entity_outline.json")));
        colorVertexer = new ColorVertexConsumerProvider(shader.getFramebuffer("main"), BleachCoreShaders::getColorOverlayShader);
    } catch (JsonSyntaxException | IOException e) {
        e.printStackTrace();
        setEnabled(false);
    }
}
Also used : Identifier(net.minecraft.util.Identifier) JsonSyntaxException(com.google.gson.JsonSyntaxException) ColorVertexConsumerProvider(org.bleachhack.util.shader.ColorVertexConsumerProvider) IOException(java.io.IOException) ShaderEffectWrapper(org.bleachhack.util.shader.ShaderEffectWrapper) ShaderEffect(net.minecraft.client.gl.ShaderEffect)

Aggregations

JsonSyntaxException (com.google.gson.JsonSyntaxException)1 IOException (java.io.IOException)1 ShaderEffect (net.minecraft.client.gl.ShaderEffect)1 Identifier (net.minecraft.util.Identifier)1 ColorVertexConsumerProvider (org.bleachhack.util.shader.ColorVertexConsumerProvider)1 ShaderEffectWrapper (org.bleachhack.util.shader.ShaderEffectWrapper)1