Class anim.DynamicDataSprite
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class anim.DynamicDataSprite

java.lang.Object
   |
   +----anim.Sprite
           |
           +----anim.DynamicDataSprite

public class DynamicDataSprite
extends Sprite
A dynamic data sprite. There are two differences between DynamicDataSprites and StaticDataSprites. 1. A DynamicDataSprite can take image data from more than one AnimImage. You can frequently assign different AnimImages to a DynamicDataSprite. 2. A DynamicDataSprite can have its input view adjusted.

Copyright (c) 1996-1997 Intel Corporation


CONSTRUCTOR INDEX

 O DynamicDataSprite()
Creates an empty DynamicDataSprite.

METHOD INDEX

 O adjustInputView(Rectangle)
Adjusts a dynamic data sprite's view port on it's input data.
 O finalize()
Called immediately before garbage collection of this object.
 O setData(AnimImage)
 O setInputView(Rectangle)
Sets a dynamic data sprite's view port on its input data.

CONSTRUCTORS

 O DynamicDataSprite
  public DynamicDataSprite()
Creates an empty DynamicDataSprite. Assign image data with setData.

METHODS

 O finalize
  protected void finalize() throws Throwable
Called immediately before garbage collection of this object.
Throws: Throwable
Never thrown. See Object.finalize for further information.
Overrides:
finalize in class Object
 O setData
  public synchronized boolean setData(AnimImage si)
 O setInputView
  public boolean setInputView(Rectangle viewPort)
Sets a dynamic data sprite's view port on its input data. The view port is the rectangular sub-area of the input to display. InputView is on the coordinate system of the sprite's AnimImage The top left corner of the InputView must lie within the AnimImage. The InputView cannot be larger than the AnimImage. If the InputView extends beyond the borders of the AnimImage, the AnimImage is wrapped to fill the InputView.
Parameters:
viewPort - the rectangle view port.
Returns:
false if the viewPort is larger than the object or has negative or zero height or width. a false value is also returned if the sprite does not currently have any data associated with it return true otherwise
See Also:
prepare, getInputView, adjustInputView
 O adjustInputView
  public boolean adjustInputView(Rectangle deltaViewPort)
Adjusts a dynamic data sprite's view port on it's input data. The view port is the rectangular sub-area of the input to display. InputView is on the coordinate system of the sprite's AnimImage The top left corner of the InputView must lie within the AnimImage. The InputView cannot be larger than the AnimImage. If the InputView extends beyond the borders of the AnimImage, the AnimImage is wrapped to fill the InputView.
Parameters:
deltaViewPort - the dleta rectangle view port.
Returns:
false if the adjusted viewPort is larger than the object or has negative or zero height or width. a false value is also returned if the sprite does not currently have any data associated with it. return true otherwise
See Also:
prepare, getInputView, setInputView

All Packages  Class Hierarchy  This Package  Previous  Next  Index
Free Web Hosting