Package org.lwjgl.opengl
Class RenderTexture
java.lang.Object
org.lwjgl.opengl.RenderTexture
This class represents the state necessary for render-to-texture.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
The TEXTURE_1D target.static final int
The TEXTURE_2D target.static final int
The TEXTURE_CUBE_MAP target.static final int
The TEXTURE_RECTANGLE target. -
Constructor Summary
ConstructorsConstructorDescriptionRenderTexture
(boolean useRGB, boolean useRGBA, boolean useDepth, boolean isRectangle, int target, int mipmaps) Creates a RenderTexture object for enabling render-to-texture on a P-buffer. -
Method Summary
-
Field Details
-
RENDER_TEXTURE_1D
public static final int RENDER_TEXTURE_1DThe TEXTURE_1D target.- See Also:
-
RENDER_TEXTURE_2D
public static final int RENDER_TEXTURE_2DThe TEXTURE_2D target.- See Also:
-
RENDER_TEXTURE_RECTANGLE
public static final int RENDER_TEXTURE_RECTANGLEThe TEXTURE_RECTANGLE target.- See Also:
-
RENDER_TEXTURE_CUBE_MAP
public static final int RENDER_TEXTURE_CUBE_MAPThe TEXTURE_CUBE_MAP target.- See Also:
-
-
Constructor Details
-
RenderTexture
public RenderTexture(boolean useRGB, boolean useRGBA, boolean useDepth, boolean isRectangle, int target, int mipmaps) Creates a RenderTexture object for enabling render-to-texture on a P-buffer. NOTE: Only one of useRGB and useRGBA can be true at the same time. NOTE: useRGB(A) and useDepth can be true at the same time, thus allowing two different render textures. NOTE: The target parameter can be one of the following: RENDER_TEXTURE_1D RENDER_TEXTURE_2D RENDER_TEXTURE_RECTANGLE RENDER_TEXTURE_CUBE_MAP- Parameters:
useRGB
- - When true the P-buffer can be used as an RGB render texture.useRGBA
- - When true the P-buffer can be used as an RGBA render texture.useDepth
- - When true the P-buffer can be used as a depth render texture.isRectangle
- - When true rectangle textures will be allowed on the P-buffer.target
- - The texture target of the render texture.mipmaps
- - How many mipmap levels to allocate on the P-buffer.
-