com.cult3d
Class TextureImage

java.lang.Object
  |
  +--java.awt.Image
        |
        +--com.cult3d.TextureImage

public class TextureImage
extends java.awt.Image

This class represents an off-screen image that can be used for painting. Use the Cult.createImage() methods to obtain a TextureImage.

Since:
Cult3D 4.0
See Also:
Cult.createImage(int, int)

Fields inherited from class java.awt.Image
SCALE_AREA_AVERAGING, SCALE_DEFAULT, SCALE_FAST, SCALE_REPLICATE, SCALE_SMOOTH, UndefinedProperty
 
Method Summary
 void flush()
          Flushes all resources being used by this Image object.
 java.awt.Graphics getGraphics()
          Returns a Graphics object that represents the drawable area of the Image.
 int getHeight(java.awt.image.ImageObserver observer)
          Returns the height of the image.
 java.lang.String getInfo()
           This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations and versions of Cult3D.
 java.lang.String getName()
          If this image has been loaded by name (Cult.getImage(String)), it returns the name of this image, otherwise it returns null
 java.lang.Object getProperty(java.lang.String name, java.awt.image.ImageObserver observer)
          Gets a property of the image by name.
 java.awt.image.ImageProducer getSource()
          Returns the ImageProducer object that produces the pixels for this image.
 int getWidth(java.awt.image.ImageObserver observer)
          Returns the width of the image.
 java.lang.String toString()
           This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations and versions of Cult3D.
 
Methods inherited from class java.awt.Image
getScaledInstance
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getWidth

public int getWidth(java.awt.image.ImageObserver observer)
Returns the width of the image.
Overrides:
getWidth in class java.awt.Image
Since:
Cult3D 4.0
See Also:
getHeight(java.awt.image.ImageObserver)

getHeight

public int getHeight(java.awt.image.ImageObserver observer)
Returns the height of the image.
Overrides:
getHeight in class java.awt.Image
Since:
Cult3D 4.0
See Also:
getWidth(java.awt.image.ImageObserver)

getSource

public java.awt.image.ImageProducer getSource()
Returns the ImageProducer object that produces the pixels for this image.
Overrides:
getSource in class java.awt.Image
Since:
Cult3D 4.0

getGraphics

public java.awt.Graphics getGraphics()
Returns a Graphics object that represents the drawable area of the Image. The Graphics object is of the type java.awt.Graphics but does not implement all the functionality of that interface. See the TextureGraphics class for more information.
Overrides:
getGraphics in class java.awt.Image
Since:
Cult3D 4.0
See Also:
TextureGraphics

getProperty

public java.lang.Object getProperty(java.lang.String name,
                                    java.awt.image.ImageObserver observer)
Gets a property of the image by name.
Overrides:
getProperty in class java.awt.Image
Since:
Cult3D 4.0

flush

public void flush()
Flushes all resources being used by this Image object.
Overrides:
flush in class java.awt.Image
Since:
Cult3D 4.0

getName

public java.lang.String getName()
If this image has been loaded by name (Cult.getImage(String)), it returns the name of this image, otherwise it returns null
Returns:
The name of the image, if loaded by name; othewise null
Since:
Cult3D 5.3

getInfo

public java.lang.String getInfo()

This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations and versions of Cult3D.

Returns:
A string representing this object.
Since:
Cult3D 5.3

toString

public java.lang.String toString()

This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations and versions of Cult3D.

Overrides:
toString in class java.lang.Object
Returns:
A string representing this object.