public class BufferedImageTexture extends SharedTexture
Modifier and Type | Field and Description |
---|---|
protected com.jogamp.opengl.util.texture.TextureCoords |
coords |
protected float |
halfHeight |
protected float |
halfWidth |
protected BufferedImage |
image |
protected com.jogamp.opengl.util.texture.Texture |
texture |
file
Constructor and Description |
---|
BufferedImageTexture(BufferedImage image) |
Modifier and Type | Method and Description |
---|---|
com.jogamp.opengl.util.texture.TextureCoords |
getCoords() |
String |
getFile()
returns null
|
float |
getHalfHeight() |
float |
getHalfWidth() |
com.jogamp.opengl.util.texture.Texture |
getTexture(com.jogamp.opengl.GL gl) |
protected void |
load(com.jogamp.opengl.GL gl,
BufferedImage image) |
void |
mount(com.jogamp.opengl.GL gl)
A GL2 context MUST be current.
|
hasMountedOnce, load
protected com.jogamp.opengl.util.texture.Texture texture
protected BufferedImage image
protected com.jogamp.opengl.util.texture.TextureCoords coords
protected float halfWidth
protected float halfHeight
public BufferedImageTexture(BufferedImage image)
public com.jogamp.opengl.util.texture.Texture getTexture(com.jogamp.opengl.GL gl)
getTexture
in class SharedTexture
public void mount(com.jogamp.opengl.GL gl)
mount
in interface IGLBindedResource
mount
in class SharedTexture
protected void load(com.jogamp.opengl.GL gl, BufferedImage image) throws com.jogamp.opengl.GLException, IOException
com.jogamp.opengl.GLException
IOException
public String getFile()
getFile
in class SharedTexture
public com.jogamp.opengl.util.texture.TextureCoords getCoords()
getCoords
in class SharedTexture
public float getHalfWidth()
getHalfWidth
in class SharedTexture
public float getHalfHeight()
getHalfHeight
in class SharedTexture
Copyright © 2016. All rights reserved.