public static void shaderActivate(String name)
{
if (OpenGlHelper.shadersSupported)
Minecraft.getMinecraft().entityRenderer.loadShader(new ResourceLocation(name));
}
if (worldIn.isRemote)
ClientProxy.shaderActivate("shaders/post/desaturate.json");//То что в кавычках, это путь до шейдера
notch, fxaa, art, bumpy, blobs2, pencil, color_convolve, deconverge, flip, invert, ntsc, outline, phosphor, scan_pincushion, sobel, bits, desaturate, green, blur, wobble, blobs, antialias, creeper, spider
public static void shaderActivate(String name)
{
if (OpenGlHelper.shadersSupported)
loadShader(new ResourceLocation(name), Minecraft.getMinecraft().theWorld);
}
public static void loadShader(ResourceLocation resourceLocationIn, World world)
{
if(world.isRemote){
Minecraft mc = Minecraft.getMinecraft();
try{
mc.entityRenderer.theShaderGroup = new ShaderGroup(mc.getTextureManager(), mc.getResourceManager(), mc.getFramebuffer(), resourceLocationIn);
}catch(JsonException e){
e.printStackTrace();
}
mc.entityRenderer.theShaderGroup.createBindFramebuffers(mc.displayWidth, mc.displayHeight);
}
}