public class RenderContext extends Object
TextureBinder
to reduce texture binds as well. Call
begin()
to setup the context, call end()
to undo all state changes. Use the setters to change state, use
textureBinder
to bind textures.Modifier and Type | Field and Description |
---|---|
TextureBinder |
textureBinder
used to bind textures
|
Constructor and Description |
---|
RenderContext(TextureBinder textures) |
Modifier and Type | Method and Description |
---|---|
void |
begin()
Sets up the render context, must be matched with a call to
end() . |
void |
end()
Resets all changed OpenGL states to their defaults.
|
void |
setBlending(boolean enabled,
int sFactor,
int dFactor) |
void |
setCullFace(int face) |
void |
setDepthMask(boolean depthMask) |
void |
setDepthTest(int depthFunction) |
void |
setDepthTest(int depthFunction,
float depthRangeNear,
float depthRangeFar) |
public final TextureBinder textureBinder
public RenderContext(TextureBinder textures)
public void begin()
end()
. Assumes that the OpenGL states are in their
defaults.public void end()
public void setDepthMask(boolean depthMask)
public void setDepthTest(int depthFunction)
public void setDepthTest(int depthFunction, float depthRangeNear, float depthRangeFar)
public void setBlending(boolean enabled, int sFactor, int dFactor)
public void setCullFace(int face)
Copyright © 2015. All rights reserved.