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

## com.obj
Class Texture

    java.lang.Object
      com.obj.Texture

    public class Texture

extends java.lang.Object

$Id$

Simple Texture containing the texture ID generated by OGL and various attributes. Can be called upon to bind and paint itself.
This is a modified version of the Texture class from: org.lwjgl.examples.spaceinvaders.Texture

Version:
  $Revision$
Author:
  Brian Matzon

Constructor Summary
`Texture(int textureID, int width, int height)` Creates a new Texture
`Texture(int textureID, int width, int height, float widthRatio, float heightRatio, int textureWidth, int textureHeight)` Creates a new Texture

Method Summary
`int` | `getHeight()`
`int` | `getTextureID()`
`int` | `getWidth()`
`java.lang.String` | `toString()` Returns a string representation of the image

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### Texture

    public Texture(int textureID,
                   int width,
                   int height)

  Creates a new Texture

  Parameters:
    `textureID` - Texture ID
    `width` - Width of image
    `height` - Height of image

### Texture

    public Texture(int textureID,
                   int width,
                   int height,
                   float widthRatio,
                   float heightRatio,
                   int textureWidth,
                   int textureHeight)

  Creates a new Texture

  Parameters:
    `textureID` - Texture ID
    `width` - Width of image
    `height` - Height of image
    `widthRatio` - Ratio of texture width
    `heightRatio` - Ratio of texture height
    `textureWidth` - Actual width of texture
    `textureHeight` - Actual height of texture

Method Detail

### getTextureID

    public int getTextureID()

  Returns:
    Texture ID for this image

### getHeight

    public int getHeight()

  Returns:
    height of image

### getWidth

    public int getWidth()

  Returns:
    width of image

### toString

    public java.lang.String toString()

  Returns a string representation of the image

  Overrides:
    `toString` in class `java.lang.Object`

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