Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.newdawn.slick.opengl
Interface Texture

All Known Implementing Classes:
  DeferredTexture, TextureImpl

    public interface Texture

The description of a texture loaded by the TextureLoader utility

Author:
  kevin

Method Summary
`void` | `bind()` Bind the GL context to a texture
`float` | `getHeight()` Get the height of the physical texture
`int` | `getImageHeight()` Get the height of the original image
`int` | `getImageWidth()` Get the width of the original image
`byte[]` | `getTextureData()` Get the pixel data from the card for this texture
`int` | `getTextureHeight()` Get the height of the actual texture
`int` | `getTextureID()` Get the OpenGL texture ID for this texture
`java.lang.String` | `getTextureRef()` Get the reference from which this texture was loaded
`int` | `getTextureWidth()` Get the width of the actual texture
`float` | `getWidth()` Get the width of the physical texture
`boolean` | `hasAlpha()` Check if the texture has alpha
`void` | `release()` Destroy the texture reference
`void` | `setTextureFilter(int textureFilter)` Apply a given texture filter to the texture

Method Detail

### hasAlpha

    boolean hasAlpha()

  Check if the texture has alpha

  Returns:
    True if the texture has alpha

### getTextureRef

    java.lang.String getTextureRef()

  Get the reference from which this texture was loaded

  Returns:
    The reference from which this texture was loaded

### bind

    void bind()

  Bind the GL context to a texture

### getImageHeight

    int getImageHeight()

  Get the height of the original image

  Returns:
    The height of the original image

### getImageWidth

    int getImageWidth()

  Get the width of the original image

  Returns:
    The width of the original image

### getHeight

    float getHeight()

  Get the height of the physical texture

  Returns:
    The height of physical texture

### getWidth

    float getWidth()

  Get the width of the physical texture

  Returns:
    The width of physical texture

### getTextureHeight

    int getTextureHeight()

  Get the height of the actual texture

  Returns:
    The height of the actual texture

### getTextureWidth

    int getTextureWidth()

  Get the width of the actual texture

  Returns:
    The width of the actual texture

### release

    void release()

  Destroy the texture reference

### getTextureID

    int getTextureID()

  Get the OpenGL texture ID for this texture

  Returns:
    The OpenGL texture ID

### getTextureData

    byte[] getTextureData()

  Get the pixel data from the card for this texture

  Returns:
    The texture data from the card for this texture

### setTextureFilter

    void setTextureFilter(int textureFilter)

  Apply a given texture filter to the texture

  Parameters:
    `textureFilter` - The texture filter to apply (GL_LINEAR, GL_NEAREST, etc..)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006 New Dawn Software. All Rights Reserved.