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
-
flags
- The flags that are used in the redraw call.
-
DSequenceFromMemory(CSequenceToMemory)
- The Movie Toolbox handles the details of decompressing image sequences in
QuickTime movies.
-
DSequenceFromMemory(EncodedImage, ImageDescription)
- This will create an DSequence object from a single piece of data and its description.
-
DSequenceFromMemory(GraphicsImporter)
- This will create an DSequence object from a single piece of data and its description.
-
DSequenceFromMemory(ImageSpec)
- This will create an DSequence object from any object that implements the
ImageSpec interface.
-
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.
-
addedToCompositor(SWCompositor, TwoDSprite)
- Returns an object that invalidates a sprite.
-
drawCurrentFrame(int)
- Your application calls this method to decompress the current frame.
-
getClip()
- Returns a region that defines the current clipping region for the object.
-
getDescription()
- This method should return an ImageDescription that describes
the image data that the class contains.
-
getDisplayBounds()
- QTCanvas calls this method when it needs to ask the client for its boundary.
-
getGraphicsMode()
- This gets the current GraphicsMode for the compositor.
-
getGWorld()
- QTCanvas calls this method to get the destination QDGraphics of its client.
-
getImage()
- This method returns the actual image data of the current frame
or null if there is no image data to return.
-
getInitialSize()
- This method returns the original size before the transformations
specified in the returned matrix are applied.
-
getMatrix()
- This will return the client's current display transformations
-
getSequence()
- Returns the CSequence object - this may return null if you haven't called
created the sequence.
-
redraw(Region)
- QTCanvas calls this method when the client should redraw itself.
-
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.
-
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.
-
setClip(Region)
- Sets a region that will define the clipping region for the object
-
setDisplayBounds(QDRect)
- QTCanvas calls this method when it needs to tell the client to adjust its
location, width and/or height.
-
setGraphicsMode(GraphicsMode)
- This sets the GraphicsMode for the Compositor when it draws its composited
contents to its destination QDGraphics (typically the QTCanvas).
-
setGWorld(QDGraphics)
- QTCanvas calls this method to give the client the QDGraphics object it should
use to do its drawing.
-
setLocation(int, int)
- A convenience method to set the position of a QTDrawable object.
-
setMatrix(Matrix)
- This will set the client's current Display Matrix
-
size()
- Return the number of image data objects (frames) that the object contains.
-
toString()
- Return a string representation of this object
flags
public int flags
- The flags that are used in the redraw call.
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.
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.
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
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
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.
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.
getGWorld
public QDGraphics getGWorld()
- QTCanvas calls this method to get the destination QDGraphics of its client.
- Returns:
- a QDGraphics object or null
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
setMatrix
public void setMatrix(Matrix matrix) throws StdQTException
- This will set the client's current Display Matrix
- Parameters:
- matrix - the new Matrix
getMatrix
public Matrix getMatrix() throws StdQTException
- This will return the client's current display transformations
- Returns:
- the display transformations of the client
getInitialSize
public Dimension getInitialSize() throws QTException
- This method returns the original size before the transformations
specified in the returned matrix are applied.
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.
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
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
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
getClip
public Region getClip() throws StdQTException
- Returns a region that defines the current clipping region for the object.
- Returns:
- the clipping region
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
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
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
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
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
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).
getGraphicsMode
public GraphicsMode getGraphicsMode()
- This gets the current GraphicsMode for the compositor.
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
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
getSequence
public DSequence getSequence()
- Returns the CSequence object - this may return null if you haven't called
created the sequence.
- Returns:
- the sequence
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