public abstract class

Texture

extends Object
implements ITexture
java.lang.Object
   ↳ org.anddev.andengine.opengl.texture.Texture
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

(c) 2010 Nicolas Gramlich (c) 2011 Zynga Inc.

Summary

Nested Classes
enum Texture.PixelFormat  
Fields
protected int mHardwareTextureID
protected boolean mLoadedToHardware
protected final Texture.PixelFormat mPixelFormat
protected final TextureOptions mTextureOptions
protected final ITexture.ITextureStateListener mTextureStateListener
protected boolean mUpdateOnHardwareNeeded
Public Constructors
Texture(Texture.PixelFormat pPixelFormat, TextureOptions pTextureOptions, ITexture.ITextureStateListener pTextureStateListener)
Public Methods
void bind(GL10 pGL)
int getHardwareTextureID()
Texture.PixelFormat getPixelFormat()
TextureOptions getTextureOptions()
ITexture.ITextureStateListener getTextureStateListener()
boolean hasTextureStateListener()
boolean isLoadedToHardware()
boolean isUpdateOnHardwareNeeded()
void loadToHardware(GL10 pGL)
void reloadToHardware(GL10 pGL)
void setLoadedToHardware(boolean pLoadedToHardware)
void setUpdateOnHardwareNeeded(boolean pUpdateOnHardwareNeeded)
void unloadFromHardware(GL10 pGL)
Protected Methods
void applyTextureOptions(GL10 pGL)
void bindTextureOnHardware(GL10 pGL)
void deleteTextureOnHardware(GL10 pGL)
void generateHardwareTextureID(GL10 pGL)
abstract void writeTextureToHardware(GL10 pGL)
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.anddev.andengine.opengl.texture.ITexture

Fields

protected int mHardwareTextureID

protected boolean mLoadedToHardware

protected final Texture.PixelFormat mPixelFormat

protected final TextureOptions mTextureOptions

protected final ITexture.ITextureStateListener mTextureStateListener

protected boolean mUpdateOnHardwareNeeded

Public Constructors

public Texture (Texture.PixelFormat pPixelFormat, TextureOptions pTextureOptions, ITexture.ITextureStateListener pTextureStateListener)

Parameters
pTextureOptions the (quality) settings of the Texture.
pTextureStateListener to be informed when this Texture is loaded, unloaded or a ITextureAtlasSource failed to load.

Public Methods

public void bind (GL10 pGL)

public int getHardwareTextureID ()

public Texture.PixelFormat getPixelFormat ()

public TextureOptions getTextureOptions ()

public ITexture.ITextureStateListener getTextureStateListener ()

public boolean hasTextureStateListener ()

public boolean isLoadedToHardware ()

public boolean isUpdateOnHardwareNeeded ()

public void loadToHardware (GL10 pGL)

Throws
IOException

public void reloadToHardware (GL10 pGL)

Throws
IOException

public void setLoadedToHardware (boolean pLoadedToHardware)

public void setUpdateOnHardwareNeeded (boolean pUpdateOnHardwareNeeded)

public void unloadFromHardware (GL10 pGL)

Protected Methods

protected void applyTextureOptions (GL10 pGL)

protected void bindTextureOnHardware (GL10 pGL)

protected void deleteTextureOnHardware (GL10 pGL)

protected void generateHardwareTextureID (GL10 pGL)

protected abstract void writeTextureToHardware (GL10 pGL)

Throws
IOException