All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class quicktime.app.image.DSequenceFromMemory

java.lang.Object
   |
   +----quicktime.app.spaces.Sequencer
           |
           +----quicktime.app.image.DSequenceFromMemory

public class DSequenceFromMemory
extends Sequencer
implements QTDrawable, DynamicImage
This class provides a mechanism for decompressing a sequence of images which were previously compressed using the CSequenceToMemory class.

The decompressed sequence is done with a number of default settings: it uses the port given to it by the displayables parent, it uses no matrix and no mask region, it uses ditherCopy as its transfer mode and it does not use an offscreen buffer or image buffer but writes directly to its destination.

See Also:
CSequenceFromMemory

Variable Index

 o flags
The flags that are used in the redraw call.

Constructor Index

 o DSequenceFromMemory(CSequenceToMemory)
The Movie Toolbox handles the details of decompressing image sequences in QuickTime movies.
 o DSequenceFromMemory(EncodedImage, ImageDescription)
This will create an DSequence object from a single piece of data and its description.
 o DSequenceFromMemory(GraphicsImporter)
This will create an DSequence object from a single piece of data and its description.
 o DSequenceFromMemory(ImageSpec)
This will create an DSequence object from any object that implements the ImageSpec interface.

Method Index

 o addedTo(Object)
This method is called by the specified object when the instance of the class that implements this interface is added to the object that is the source of the interest.
 o addedToCompositor(SWCompositor, TwoDSprite)
Returns an object that invalidates a sprite.
 o drawCurrentFrame(int)
Your application calls this method to decompress the current frame.
 o getClip()
Returns a region that defines the current clipping region for the object.
 o getDescription()
This method should return an ImageDescription that describes the image data that the class contains.
 o getDisplayBounds()
QTCanvas calls this method when it needs to ask the client for its boundary.
 o getGraphicsMode()
This gets the current GraphicsMode for the compositor.
 o getGWorld()
QTCanvas calls this method to get the destination QDGraphics of its client.
 o getImage()
This method returns the actual image data of the current frame or null if there is no image data to return.
 o getInitialSize()
This method returns the original size before the transformations specified in the returned matrix are applied.
 o getMatrix()
This will return the client's current display transformations
 o getSequence()
Returns the CSequence object - this may return null if you haven't called created the sequence.
 o redraw(Region)
QTCanvas calls this method when the client should redraw itself.
 o removedFrom(Object)
This method is called by the specified object when the instance of the class that implements this interface is removed from the object that is the source of the interest.
 o removedFromCompositor(SWCompositor)
When a dynamic image class is removed from a SWCompositor this method is called to allow the class to cleanup any of the invalidation processes it had established in the addedToCompositor call.
 o setClip(Region)
Sets a region that will define the clipping region for the object
 o setDisplayBounds(QDRect)
QTCanvas calls this method when it needs to tell the client to adjust its location, width and/or height.
 o setGraphicsMode(GraphicsMode)
This sets the GraphicsMode for the Compositor when it draws its composited contents to its destination QDGraphics (typically the QTCanvas).
 o setGWorld(QDGraphics)
QTCanvas calls this method to give the client the QDGraphics object it should use to do its drawing.
 o setLocation(int, int)
A convenience method to set the position of a QTDrawable object.
 o setMatrix(Matrix)
This will set the client's current Display Matrix
 o size()
Return the number of image data objects (frames) that the object contains.
 o toString()
Return a string representation of this object

Variables

 o flags
 public int flags
The flags that are used in the redraw call.

Constructors

 o DSequenceFromMemory
 public DSequenceFromMemory(GraphicsImporter importer) throws QTException
This will create an DSequence object from a single piece of data and its description. It will NOT copy the incoming image, but will merely add them to the internal data storage.

Parameters:
data - the image data object.
description - the ImageDescription object.
 o DSequenceFromMemory
 public DSequenceFromMemory(EncodedImage data,
                            ImageDescription description) throws QTException
This will create an DSequence object from a single piece of data and its description. It will NOT copy the incoming image, but will merely add them to the internal data storage.

Parameters:
data - the image data object.
description - the ImageDescription object.
 o DSequenceFromMemory
 public DSequenceFromMemory(CSequenceToMemory sequenceInMemory) throws QTException
The Movie Toolbox handles the details of decompressing image sequences in QuickTime movies. If you need to decompress other sequences which were compressed via the CSequenceToMemory class, your application can create an instance of this DSequenceFromMemory class.

Parameters:
sequenceInMemory - a previously created CSequenceToMemory object
 o DSequenceFromMemory
 public DSequenceFromMemory(ImageSpec spec) throws QTException
This will create an DSequence object from any object that implements the ImageSpec interface. It will NOT copy the incoming image, but will merely add it to the internal data storage.

Parameters:
spec - the ImageSpec object

Methods

 o addedTo
 public void addedTo(Object interest)
This method is called by the specified object when the instance of the class that implements this interface is added to the object that is the source of the interest.

Parameters:
interest - the object that is to be the source of interest for the the object that implements this interface.
 o removedFrom
 public void removedFrom(Object interest)
This method is called by the specified object when the instance of the class that implements this interface is removed from the object that is the source of the interest.

Parameters:
interest - the object that was the source of interest for the the object that implements this interface.
 o getGWorld
 public QDGraphics getGWorld()
QTCanvas calls this method to get the destination QDGraphics of its client.

Returns:
a QDGraphics object or null
 o setGWorld
 public void setGWorld(QDGraphics cgp) throws QTException
QTCanvas calls this method to give the client the QDGraphics object it should use to do its drawing. If the incoming QDGraphics is the QDGraphics.scratch then the drawable will not be visible and can disable itself. If a client is unable to set the graphics world it should throw an exception.

Parameters:
cgp - a QDGraphics object
 o setMatrix
 public void setMatrix(Matrix matrix) throws StdQTException
This will set the client's current Display Matrix

Parameters:
matrix - the new Matrix
 o getMatrix
 public Matrix getMatrix() throws StdQTException
This will return the client's current display transformations

Returns:
the display transformations of the client
 o getInitialSize
 public Dimension getInitialSize() throws QTException
This method returns the original size before the transformations specified in the returned matrix are applied.

 o setDisplayBounds
 public void setDisplayBounds(QDRect bounds) throws StdQTException
QTCanvas calls this method when it needs to tell the client to adjust its location, width and/or height. All values are in pixels.

Parameters:
bounds - the new size and location.
 o setLocation
 public void setLocation(int x,
                         int y) throws QTException
A convenience method to set the position of a QTDrawable object.

Parameters:
x - the new x location
y - the new y location
 o getDisplayBounds
 public QDRect getDisplayBounds()
QTCanvas calls this method when it needs to ask the client for its boundary. All values are in pixels.

Returns:
the boundary of the client
 o redraw
 public final synchronized void redraw(Region invalidRgn) throws StdQTException
QTCanvas calls this method when the client should redraw itself. If the canvas is able to discern that only a part of the client's drawing area needs to be redrawn - then this area shall be passed in using the invalidRgn. Otherwise this will be null in which case the client should redraw itself entirely.

Parameters:
invalidRgn - the invalidRgn that the client should redraw
 o getClip
 public Region getClip() throws StdQTException
Returns a region that defines the current clipping region for the object.

Returns:
the clipping region
 o setClip
 public void setClip(Region reg) throws StdQTException
Sets a region that will define the clipping region for the object

Parameters:
reg - the new clipping region
 o getDescription
 public ImageDescription getDescription() throws QTException
This method should return an ImageDescription that describes the image data that the class contains.

Returns:
the ImageDescription of an Image
 o getImage
 public EncodedImage getImage() throws StdQTException
This method returns the actual image data of the current frame or null if there is no image data to return.

Returns:
the image data
 o size
 public int size()
Return the number of image data objects (frames) that the object contains.

Returns:
the number of frames if the image is the sequence of frames
Overrides:
size in class Sequencer
 o drawCurrentFrame
 public int drawCurrentFrame(int inFlags) throws StdQTException
Your application calls this method to decompress the current frame.
Note: See the QTImage class and Inside Mac QuickTime documentation for more information on valid flag values.

Parameters:
inFlags - flags providing further control information
Returns:
the outFlags value
 o setGraphicsMode
 public void setGraphicsMode(GraphicsMode mode) throws QTException
This sets the GraphicsMode for the Compositor when it draws its composited contents to its destination QDGraphics (typically the QTCanvas).

 o getGraphicsMode
 public GraphicsMode getGraphicsMode()
This gets the current GraphicsMode for the compositor.

 o addedToCompositor
 public Invalidator addedToCompositor(SWCompositor c,
                                      TwoDSprite s)
Returns an object that invalidates a sprite. When a DynamicImage is a member of a SWompositor and the DynamicImage presents a changing image (for example a movie), the TwoDSprite that presents that image in the SWCompositor must be invalidated so that it will redraw the Sprites image in the next composit cycle. The Invalidator object is used to perform this function by the SWCompositor if the object itself cannot perform the invalidation. Can return null if the DynamicImage does not require the SWCompositor to invalidate it (or the object is in a state where its image won't change).

The Invalidators provided with objects that implement the DynamicImage interface will execute at the scale and period of the Compositor when they are created.

Parameters:
c - the Compositor in which the DynamicImage is a member
s - the TwoDSprite that is presenting the DynamicImage's image in the Compositor. This is the sprite that must be invalidated.
Returns:
an Invalidator or null if invalidation is not required
See Also:
SWCompositor
 o removedFromCompositor
 public void removedFromCompositor(SWCompositor c)
When a dynamic image class is removed from a SWCompositor this method is called to allow the class to cleanup any of the invalidation processes it had established in the addedToCompositor call.

Parameters:
c - the SWCompositor it is being removed from
 o getSequence
 public DSequence getSequence()
Returns the CSequence object - this may return null if you haven't called created the sequence.

Returns:
the sequence
 o toString
 public String toString()
Return a string representation of this object

Overrides:
toString in class Sequencer

All Packages  Class Hierarchy  This Package  Previous  Next  Index