mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-18 19:39:09 +00:00
24 lines
708 B
Java
24 lines
708 B
Java
package com.prupe.mcpatcher.mal.resource;
|
|
|
|
import org.lwjgl.opengl.GL11;
|
|
import com.gtnewhorizons.angelica.glsm.GLStateManager;
|
|
|
|
public class GLAPI {
|
|
|
|
private static final boolean useGlBlendFuncSeparate = GLStateManager.capabilities.OpenGL14;
|
|
|
|
public static void glBindTexture(int texture) {
|
|
if (texture >= 0) {
|
|
GLStateManager.glBindTexture(GL11.GL_TEXTURE_2D, texture);
|
|
}
|
|
}
|
|
|
|
public static void glBlendFuncSeparate(int src, int dst, int srcAlpha, int dstAlpha) {
|
|
if (useGlBlendFuncSeparate) {
|
|
GLStateManager.glBlendFuncSeparate(src, dst, srcAlpha, dstAlpha);
|
|
} else {
|
|
GLStateManager.glBlendFunc(src, dst);
|
|
}
|
|
}
|
|
}
|