Java Code Examples for org.lwjgl.opengl.GL14#glBlendFuncSeparate()
The following examples show how to use
org.lwjgl.opengl.GL14#glBlendFuncSeparate() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Variables.java From The-5zig-Mod with MIT License | 5 votes |
public void renderItem(add itemStack, int x, int y) { bam.c(); GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(770, 771, 1, 0); GL11.glDisable(GL11.GL_LIGHTING); itemRenderer.a(getFontrenderer(), getTextureManager(), itemStack, x, y); itemRenderer.c(getFontrenderer(), getTextureManager(), itemStack, x, y); GL11.glEnable(GL11.GL_LIGHTING); GL11.glDisable(GL11.GL_BLEND); bam.a(); }
Example 2
Source File: RenderUtils.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void gl11Setup() { GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glLineWidth(2.5F); GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glMatrixMode(5889); GL11.glEnable(GL11.GL_LINE_SMOOTH); GL11.glPushMatrix(); }
Example 3
Source File: RenderUtilsLiving.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void glSetup(double x, double y, double z) { GL11.glPushMatrix(); GL11.glTranslated(x - RenderUtils.renderPos().x, y - RenderUtils.renderPos().y, z - RenderUtils.renderPos().z); GL11.glNormal3f(0.0F, 1.0F, 0.0F); GL11.glRotatef(-mc.player.yaw, 0.0F, 1.0F, 0.0F); GL11.glRotatef(mc.player.pitch, 1.0F, 0.0F, 0.0F); GL11.glDisable(GL11.GL_LIGHTING); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); }
Example 4
Source File: Window.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
private void fillGradient(int x1, int y1, int x2, int y2, int color1, int color2) { float float_1 = (float)(color1 >> 24 & 255) / 255.0F; float float_2 = (float)(color1 >> 16 & 255) / 255.0F; float float_3 = (float)(color1 >> 8 & 255) / 255.0F; float float_4 = (float)(color1 & 255) / 255.0F; float float_5 = (float)(color2 >> 24 & 255) / 255.0F; float float_6 = (float)(color2 >> 16 & 255) / 255.0F; float float_7 = (float)(color2 >> 8 & 255) / 255.0F; float float_8 = (float)(color2 & 255) / 255.0F; GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glEnable(GL11.GL_BLEND); GL11.glDisable(GL11.GL_ALPHA_TEST); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glShadeModel(7425); Tessellator tessellator_1 = Tessellator.getInstance(); BufferBuilder bufferBuilder_1 = tessellator_1.getBufferBuilder(); bufferBuilder_1.begin(7, VertexFormats.POSITION_COLOR); bufferBuilder_1.vertex((double)x1, (double)y1, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x1, (double)y2, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x2, (double)y2, 0).color(float_6, float_7, float_8, float_5).next(); bufferBuilder_1.vertex((double)x2, (double)y1, 0).color(float_6, float_7, float_8, float_5).next(); tessellator_1.draw(); GL11.glShadeModel(7424); GL11.glDisable(GL11.GL_BLEND); GL11.glEnable(GL11.GL_ALPHA_TEST); GL11.glEnable(GL11.GL_TEXTURE_2D); }
Example 5
Source File: RenderUtils.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void gl11Setup() { GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glLineWidth(2.5F); GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glMatrixMode(5889); GL11.glPushMatrix(); }
Example 6
Source File: RenderUtilsLiving.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void glSetup(double x, double y, double z) { GL11.glPushMatrix(); GL11.glTranslated(x - RenderUtils.renderPos().x, y - RenderUtils.renderPos().y, z - RenderUtils.renderPos().z); GL11.glNormal3f(0.0F, 1.0F, 0.0F); GL11.glRotatef(-mc.getRenderManager().playerViewY, 0.0F, 1.0F, 0.0F); GL11.glRotatef(mc.getRenderManager().playerViewX, 1.0F, 0.0F, 0.0F); GL11.glDisable(GL11.GL_LIGHTING); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); }
Example 7
Source File: RenderUtils.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void gl11Setup() { GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glLineWidth(2.5F); GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glMatrixMode(5889); GL11.glEnable(GL11.GL_LINE_SMOOTH); GL11.glPushMatrix(); offsetRender(); }
Example 8
Source File: RenderUtilsLiving.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void glSetup(double x, double y, double z) { GL11.glPushMatrix(); RenderUtils.offsetRender(); GL11.glTranslated(x, y, z); GL11.glNormal3f(0.0F, 1.0F, 0.0F); GL11.glRotatef(-mc.player.yaw, 0.0F, 1.0F, 0.0F); GL11.glRotatef(mc.player.pitch, 1.0F, 0.0F, 0.0F); //GL11.glDisable(GL11.GL_LIGHTING); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); }
Example 9
Source File: Window.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
protected void fillGradient(MatrixStack matrix, int x1, int y1, int x2, int y2, int color1, int color2) { float float_1 = (float)(color1 >> 24 & 255) / 255.0F; float float_2 = (float)(color1 >> 16 & 255) / 255.0F; float float_3 = (float)(color1 >> 8 & 255) / 255.0F; float float_4 = (float)(color1 & 255) / 255.0F; float float_5 = (float)(color2 >> 24 & 255) / 255.0F; float float_6 = (float)(color2 >> 16 & 255) / 255.0F; float float_7 = (float)(color2 >> 8 & 255) / 255.0F; float float_8 = (float)(color2 & 255) / 255.0F; GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glEnable(GL11.GL_BLEND); GL11.glDisable(GL11.GL_ALPHA_TEST); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glShadeModel(7425); Tessellator tessellator_1 = Tessellator.getInstance(); BufferBuilder bufferBuilder_1 = tessellator_1.getBuffer(); bufferBuilder_1.begin(7, VertexFormats.POSITION_COLOR); bufferBuilder_1.vertex((double)x1, (double)y1, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x1, (double)y2, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x2, (double)y2, 0).color(float_6, float_7, float_8, float_5).next(); bufferBuilder_1.vertex((double)x2, (double)y1, 0).color(float_6, float_7, float_8, float_5).next(); tessellator_1.draw(); GL11.glShadeModel(7424); GL11.glDisable(GL11.GL_BLEND); GL11.glEnable(GL11.GL_ALPHA_TEST); GL11.glEnable(GL11.GL_TEXTURE_2D); }
Example 10
Source File: RenderUtils.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void gl11Setup() { GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glLineWidth(2.5F); GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glMatrixMode(5889); GL11.glEnable(GL11.GL_LINE_SMOOTH); GL11.glPushMatrix(); offsetRender(); }
Example 11
Source File: RenderUtilsLiving.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
public static void glSetup(double x, double y, double z) { GL11.glPushMatrix(); RenderUtils.offsetRender(); GL11.glTranslated(x, y, z); GL11.glNormal3f(0.0F, 1.0F, 0.0F); GL11.glRotatef(-mc.player.yaw, 0.0F, 1.0F, 0.0F); GL11.glRotatef(mc.player.pitch, 1.0F, 0.0F, 0.0F); //GL11.glDisable(GL11.GL_LIGHTING); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_BLEND); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); }
Example 12
Source File: Window.java From bleachhack-1.14 with GNU General Public License v3.0 | 5 votes |
protected void fillGradient(int x1, int y1, int x2, int y2, int color1, int color2) { float float_1 = (float)(color1 >> 24 & 255) / 255.0F; float float_2 = (float)(color1 >> 16 & 255) / 255.0F; float float_3 = (float)(color1 >> 8 & 255) / 255.0F; float float_4 = (float)(color1 & 255) / 255.0F; float float_5 = (float)(color2 >> 24 & 255) / 255.0F; float float_6 = (float)(color2 >> 16 & 255) / 255.0F; float float_7 = (float)(color2 >> 8 & 255) / 255.0F; float float_8 = (float)(color2 & 255) / 255.0F; GL11.glDisable(GL11.GL_TEXTURE_2D); GL11.glEnable(GL11.GL_BLEND); GL11.glDisable(GL11.GL_ALPHA_TEST); GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO); GL11.glShadeModel(7425); Tessellator tessellator_1 = Tessellator.getInstance(); BufferBuilder bufferBuilder_1 = tessellator_1.getBuffer(); bufferBuilder_1.begin(7, VertexFormats.POSITION_COLOR); bufferBuilder_1.vertex((double)x1, (double)y1, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x1, (double)y2, 0).color(float_2, float_3, float_4, float_1).next(); bufferBuilder_1.vertex((double)x2, (double)y2, 0).color(float_6, float_7, float_8, float_5).next(); bufferBuilder_1.vertex((double)x2, (double)y1, 0).color(float_6, float_7, float_8, float_5).next(); tessellator_1.draw(); GL11.glShadeModel(7424); GL11.glDisable(GL11.GL_BLEND); GL11.glEnable(GL11.GL_ALPHA_TEST); GL11.glEnable(GL11.GL_TEXTURE_2D); }