quicktime.app.anim
Class TwoDSpriteInfo

java.lang.Object
  |
  +--quicktime.app.anim.TwoDSpriteInfo
All Implemented Interfaces:
ImageSpec, java.io.Serializable

public final class TwoDSpriteInfo
extends java.lang.Object
implements ImageSpec, java.io.Serializable

This class can be used to retain the current sprite settings which can be used at a later stage to reset the TwoDSprite to those settings. The EncodedImage and ImageDescription of the TwoDSpriteInfo class are transient and thus will not be saved when this object is serialized. Applications should use a QuickTime movie or other means of saving image data.

See Also:
TwoDSprite, Serialized Form

Constructor Summary
TwoDSpriteInfo(EncodedImage im, ImageDescription d, Matrix m, boolean v, int l)
          Contains the information that can be used to create a sprite.
TwoDSpriteInfo(EncodedImage im, ImageDescription d, Matrix m, boolean v, int l, GraphicsMode gm)
          Contains the information that can be used to create a sprite.
 
Method Summary
 ImageDescription getDescription()
          This method should return an ImageDescription that describes the image data that the class contains.
 GraphicsMode getGraphicsMode()
           
 EncodedImage getImage()
          This method returns the actual image data.
 int getLayer()
           
 Matrix getMatrix()
           
 boolean getVisible()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TwoDSpriteInfo

public TwoDSpriteInfo(EncodedImage im,
                      ImageDescription d,
                      Matrix m,
                      boolean v,
                      int l)
Contains the information that can be used to create a sprite.
Parameters:
im - the image of the sprite
d - the image description that describes the format of the im
m - the display matrix applied to the sprite
v - if true the sprite is/was visible
l - the layer of the sprite in its sprite world

TwoDSpriteInfo

public TwoDSpriteInfo(EncodedImage im,
                      ImageDescription d,
                      Matrix m,
                      boolean v,
                      int l,
                      GraphicsMode gm)
Contains the information that can be used to create a sprite.
Parameters:
im - the image of the sprite
d - the image description that describes the format of the im
m - the display matrix applied to the sprite
l - the layer of the sprite in its sprite world
v - if true the sprite is/was visible
gm - the GraphicsMode (or null)
Method Detail

getImage

public EncodedImage getImage()
Description copied from interface: ImageSpec
This method returns the actual image data. An Exception is throw if there was some problem retrieving the data.
Specified by:
getImage in interface ImageSpec
Returns:
The current image data of the sprite

getDescription

public ImageDescription getDescription()
Description copied from interface: ImageSpec
This method should return an ImageDescription that describes the image data that the class contains.
Specified by:
getDescription in interface ImageSpec
Returns:
The description that describes the image

getMatrix

public Matrix getMatrix()
Returns:
The display matrix of the Sprite

getLayer

public int getLayer()
Returns:
The layer of the sprite in its SpriteWorld

getVisible

public boolean getVisible()
Returns:
The visibility of the sprite

getGraphicsMode

public GraphicsMode getGraphicsMode()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
a String representation of this object