All Packages Class Hierarchy This Package Previous Next Index
java.lang.Object | +----quicktime.app.actions.Invalidator
The SWCompositor uses QuickTime's SpriteWorld to draw a member's image. If the member's image data is changing but there are no changes in the presentation of the member's Sprite (a QuickTime Sprite is used to represent the member in the SpriteWorld of the SWCompositor) then the compositing cycle of the SpriteWorld will not redraw the Sprite. Thus in order to force the SpriteWorld to redraw a Sprite of this nature, the Sprite that is presenting the member must be invalidated.
Some classes explicitly use the Invalidator class in this release, the CompositableEffect and QTImageDrawer. Implicit invalidation is done in other classes (MoviePresenter, the SWCompositor itself if it a member of a parent SWCompositor) as they possess their own sense of drawing.
If an Invalidator is required it is returned by the addedToCompositor method and the SWCompositor keeps a list of the Invalidators and invokes the invalidator each time the SWCompositor itself is tickled. Subclasses of the Invalidator class can override the tickle method and be more efficient based on the explicit conditions under which the TwoDSprite is invalidated. For example if a QTImageDrawer is not redrawing every time the TwoDSprite needs only to be invalidated when the QTImageDrawer signifies that it is redrawing. Thus the Invalidator for the QTImageDrawer checks isRedrawing() and only redraws and invalidates the presenting Sprite if the QTImageDrawer returns true from the isRedrawing() call. It will still ask the QTImageDrawer if it requires redrawing upon each composit loop when the Invalidator itself is activated.
protected TwoDSprite s
public Invalidator(TwoDSprite s)
public TwoDSprite getTarget()
public void timeChanged(int newTime) throws QTException
public boolean tickle(float er, int t) throws QTException
All Packages Class Hierarchy This Package Previous Next Index