diff --git a/src/main/java/de/bixilon/minosoft/gui/rendering/shader/ShaderUtil.java b/src/main/java/de/bixilon/minosoft/gui/rendering/shader/ShaderUtil.java index 0a7c0a301..b3c29ca46 100644 --- a/src/main/java/de/bixilon/minosoft/gui/rendering/shader/ShaderUtil.java +++ b/src/main/java/de/bixilon/minosoft/gui/rendering/shader/ShaderUtil.java @@ -8,21 +8,22 @@ import org.lwjgl.opengl.GL11; import java.io.IOException; +import static org.lwjgl.opengl.ARBShaderObjects.*; import static org.lwjgl.system.MemoryUtil.NULL; public class ShaderUtil { public static int createShader(String shaderPath, int shaderType) throws ShaderLoadingException, IOException { - int shaderId = ARBShaderObjects.glCreateShaderObjectARB(shaderType); + int shaderId = glCreateShaderObjectARB(shaderType); if (shaderId == NULL) { throw new ShaderLoadingException(); } - ARBShaderObjects.glShaderSourceARB(shaderId, Util.readAssetResource("/rendering/shader/" + shaderPath)); - ARBShaderObjects.glCompileShaderARB(shaderId); + glShaderSourceARB(shaderId, Util.readAssetResource("rendering/shader/" + shaderPath)); + glCompileShaderARB(shaderId); - if (ARBShaderObjects.glGetObjectParameteriARB(shaderId, ARBShaderObjects.GL_OBJECT_COMPILE_STATUS_ARB) == GL11.GL_FALSE) { + if (glGetObjectParameteriARB(shaderId, ARBShaderObjects.GL_OBJECT_COMPILE_STATUS_ARB) == GL11.GL_FALSE) { throw new ShaderLoadingException(OpenGLUtil.getLogInfo(shaderId)); }