quicktime.std.image
Class DSequence

java.lang.Object
  |
  +--quicktime.QTObject
        |
        +--quicktime.std.image.CDSequence
              |
              +--quicktime.std.image.DSequence
All Implemented Interfaces:
quicktime.jdirect.InterfaceLib, quicktime.jdirect.PrimitivesLib, quicktime.jdirect.QuickTimeLib, quicktime.jdirect.SharedLibrary, com.apple.jdirect.SharedLibrary

public final class DSequence
extends CDSequence

This class is used for decompressing a sequence of images. The Movie Toolbox handles the details of decompressing image sequences in QuickTime movies. If you need to decompress other sequences, your application can use this class.

See Also:
CDSequence, CSequence

Fields inherited from interface quicktime.jdirect.QuickTimeLib
JDirect_MacOSX, libraryInstance, name
 
Constructor Summary
DSequence(ImageDescription desc, EncodedImage data, QDGraphics port, QDRect srcRect, Matrix matrix, Region mask, int flags, int accuracy, CodecComponent codec)
          This constructor allows you to pass a compressed sample so the codec can perform preflighting before the first decompressFrame call.
DSequence(ImageDescription desc, QDGraphics port, QDRect srcRect, Matrix matrix, Region mask, int flags, int accuracy, CodecComponent codec)
          Creating an instance of this class signals the beginning of the process of decompressing a sequence of frames.
 
Method Summary
 int decompressFrame(ByteEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrame(EncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrame(IntEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrame(RawEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrameS(ByteEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrameS(EncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrameS(IntEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrameS(RawEncodedImage data, int inFlags)
          Your application calls this method to decompress one of a sequence of frames.
 int decompressFrameWhen(ByteEncodedImage data, int inFlags, ICMFrameTime frameTime)
          Queues a frame for decompression and specifies the time at which decompression will begin.
 int decompressFrameWhen(EncodedImage data, int inFlags, ICMFrameTime frameTime)
          Queues a frame for decompression and specifies the time at which decompression will begin.
 int decompressFrameWhen(IntEncodedImage data, int inFlags, ICMFrameTime frameTime)
          Queues a frame for decompression and specifies the time at which decompression will begin.
 int decompressFrameWhen(RawEncodedImage data, int inFlags, ICMFrameTime frameTime)
          Queues a frame for decompression and specifies the time at which decompression will begin.
 void flush()
          Stops a decompression sequence, aborting processing of any queued frames.
 QDGraphics getImageBuffer()
          This method helps you determine the location of the offscreen image buffer allocated by the decompressor.
 Matrix getMatrix()
          This method returns the matrix associated with the sequence
 QDGraphics getScreenBuffer()
          This method enables you to determine the location of the offscreen buffer allocated by the decompressor.
 boolean hitTestData(EncodedImage data, QDPoint where, int hitFlags)
          The HitTestDSequenceData function allows the calling application to perform hit testing on compressed data.
 void invalidate(Region invalRgn)
          Notifies the Image Compression Manager that the destination port for the given image decompression sequence has been invalidated.
 boolean ptInData(EncodedImage data, QDPoint where)
          Tests to see if an image contains data at a given point.
 void setAccuracy(int accuracy)
          This method adjusts the decompression accuracy for this sequence.
 void setFlags(int flags, int flagsMask)
          This method sets the flags of the image sequence
 void setGraphicsMode(GraphicsMode mode)
          This method sets the mode used when drawing the decompressed image.
 void setMask(Region mask)
          This method assigns a clipping region to the sequence.
 void setMatrix(Matrix matrix)
          This method assigns a mapping matrix to the sequence.
 void setMatte(PixMap matte, QDRect matteRect)
          This method assigns a blend matte to the sequence.
 void setSrcRect(QDRect srcRect)
          This method defines the portion of the image to decompress.
 void setTimeCode(TimeCodeDef timeCodeFormat, TimeCodeTime timeCodeTime)
          Sets the timecode value for the frame that is about to be decompressed.
 void setTransferMode(int mode, QDColor opColor)
          This method sets the mode used when drawing the decompressed image.
 void shieldCursor()
          Hides the cursor during decompression operations.
 
Methods inherited from class quicktime.std.image.CDSequence
busy, equivalentImageDescription, getDescription, setTimeBase
 
Methods inherited from class quicktime.QTObject
disposeQTObject, equals, ID, toString
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DSequence

public DSequence(ImageDescription desc,
                 QDGraphics port,
                 QDRect srcRect,
                 Matrix matrix,
                 Region mask,
                 int flags,
                 int accuracy,
                 CodecComponent codec)
          throws QTException
Creating an instance of this class signals the beginning of the process of decompressing a sequence of frames.

QuickTime::DecompressSequenceBegin

Parameters:
desc - an ImageDescription object which describes the compressed data
port - a QDGraphics for the destination image. This may NOT be null.
srcRect - a QDRect defining the portion of the image to decompress, or null to use the rectangle defined in the ImageDescription associated with this sequence
matrix - a Matrix that specifies how to transform the image during decompression
mask - a RgnHandle which defines a clipping region in the destination coordinate system, or null
flags - flags providing further control information
accuracy - the accuracy desired in the decompressed image
codec - a Decompressor identifier

DSequence

public DSequence(ImageDescription desc,
                 EncodedImage data,
                 QDGraphics port,
                 QDRect srcRect,
                 Matrix matrix,
                 Region mask,
                 int flags,
                 int accuracy,
                 CodecComponent codec)
          throws QTException
This constructor allows you to pass a compressed sample so the codec can perform preflighting before the first decompressFrame call.

QuickTime::DecompressSequenceBeginS

Parameters:
desc - an ImageDescription object which describes the compressed data
data - encoded image data
port - a QDGraphics for the destination image. This may NOT be null.
srcRect - a QDRect defining the portion of the image to decompress, or null to use the rectangle defined in the ImageDescription associated with this sequence
matrix - a Matrix that specifies how to transform the image during decompression
mask - a RgnHandle which defines a clipping region in the destination coordinate system, or null
flags - flags providing further control information
accuracy - the accuracy desired in the decompressed image
codec - a Decompressor identifier
Method Detail

decompressFrameS

public int decompressFrameS(EncodedImage data,
                            int inFlags)
                     throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrameS

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrameS

public int decompressFrameS(ByteEncodedImage data,
                            int inFlags)
                     throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrameS

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrameS

public int decompressFrameS(IntEncodedImage data,
                            int inFlags)
                     throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrameS

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrameS

public int decompressFrameS(RawEncodedImage data,
                            int inFlags)
                     throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrameS

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrame

public int decompressFrame(EncodedImage data,
                           int inFlags)
                    throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrame

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrame

public int decompressFrame(ByteEncodedImage data,
                           int inFlags)
                    throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrame

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrame

public int decompressFrame(IntEncodedImage data,
                           int inFlags)
                    throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrame

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrame

public int decompressFrame(RawEncodedImage data,
                           int inFlags)
                    throws StdQTException
Your application calls this method to decompress one of a sequence of frames.

QuickTime::DecompressSequenceFrame

Parameters:
data - encoded image data
inFlags - flags providing further control information
Returns:
the outFlags value

decompressFrameWhen

public int decompressFrameWhen(ByteEncodedImage data,
                               int inFlags,
                               ICMFrameTime frameTime)
                        throws StdQTException
Queues a frame for decompression and specifies the time at which decompression will begin.

QuickTime::DecompressSequenceFrameWhen

Parameters:
data - encoded image data
inFlags - flags providing further control information
frameTime - an ICMFrameTime object that contains the frame's time information, including the time at which the frame should be displayed, its duration, and the movie's playback rate.
Returns:
the outFlags value

decompressFrameWhen

public int decompressFrameWhen(IntEncodedImage data,
                               int inFlags,
                               ICMFrameTime frameTime)
                        throws StdQTException
Queues a frame for decompression and specifies the time at which decompression will begin.

QuickTime::DecompressSequenceFrameWhen

Parameters:
data - encoded image data
inFlags - flags providing further control information
frameTime - an ICMFrameTime object that contains the frame's time information, including the time at which the frame should be displayed, its duration, and the movie's playback rate.
Returns:
the outFlags value

decompressFrameWhen

public int decompressFrameWhen(RawEncodedImage data,
                               int inFlags,
                               ICMFrameTime frameTime)
                        throws StdQTException
Queues a frame for decompression and specifies the time at which decompression will begin.

QuickTime::DecompressSequenceFrameWhen

Parameters:
data - encoded image data
inFlags - flags providing further control information
frameTime - an ICMFrameTime object that contains the frame's time information, including the time at which the frame should be displayed, its duration, and the movie's playback rate.
Returns:
the outFlags value

decompressFrameWhen

public int decompressFrameWhen(EncodedImage data,
                               int inFlags,
                               ICMFrameTime frameTime)
                        throws StdQTException
Queues a frame for decompression and specifies the time at which decompression will begin.

QuickTime::DecompressSequenceFrameWhen

Parameters:
data - encoded image data
inFlags - flags providing further control information
frameTime - an ICMFrameTime object that contains the frame's time information, including the time at which the frame should be displayed, its duration, and the movie's playback rate.
Returns:
the outFlags value

setGraphicsMode

public void setGraphicsMode(GraphicsMode mode)
                     throws StdQTException
This method sets the mode used when drawing the decompressed image.

QuickTime::SetDSequenceTransferMode

Parameters:
mode - the transfer mode to use when drawing the decompressed image

setTransferMode

public void setTransferMode(int mode,
                            QDColor opColor)
                     throws StdQTException
This method sets the mode used when drawing the decompressed image.

QuickTime::SetDSequenceTransferMode

Parameters:
mode - the transfer mode to use when drawing the decompressed image
opColor - an QDColor object to be used in addPin, subPin, blend and transparent operations. If null, the opColor is left unchanged.

setSrcRect

public void setSrcRect(QDRect srcRect)
                throws StdQTException
This method defines the portion of the image to decompress.

QuickTime::SetDSequenceSrcRect

Parameters:
srcRect - a QDRect object defining the portion of the object to decompress

setMatrix

public void setMatrix(Matrix matrix)
               throws StdQTException
This method assigns a mapping matrix to the sequence.

QuickTime::SetDSequenceMatrix

Parameters:
matrix - a Matrix object that specifies how to transform the image during decompression

getMatrix

public Matrix getMatrix()
                 throws StdQTException
This method returns the matrix associated with the sequence
Returns:
Matrix a matrix object that specifies the transform of the image sequence

setFlags

public void setFlags(int flags,
                     int flagsMask)
              throws StdQTException
This method sets the flags of the image sequence
Parameters:
flags - the flags associated with the sequence
flagsMask - the masks to use for filtering out unwanted flags

setMask

public void setMask(Region mask)
             throws StdQTException
This method assigns a clipping region to the sequence.

QuickTime::SetDSequenceMask

Parameters:
mask - a Region object which is applied to the desitnation image. If null then masking is stopped.

setMatte

public void setMatte(PixMap matte,
                     QDRect matteRect)
              throws StdQTException
This method assigns a blend matte to the sequence.

QuickTime::SetDSequenceMatte

Parameters:
matte - a PixMap object which contains a blend matte
matteRect - a QDRect object which defines the boundary of the matte

setAccuracy

public void setAccuracy(int accuracy)
                 throws StdQTException
This method adjusts the decompression accuracy for this sequence.

QuickTime::SetDSequenceAccuracy

Parameters:
accuracy - the accuracy desired in the decompressed image

getImageBuffer

public QDGraphics getImageBuffer()
                          throws StdQTException
This method helps you determine the location of the offscreen image buffer allocated by the decompressor.

QuickTime::GetDSequenceImageBuffer

Returns:
a QDGraphics object which is the graphics world for the image buffer

getScreenBuffer

public QDGraphics getScreenBuffer()
                           throws StdQTException
This method enables you to determine the location of the offscreen buffer allocated by the decompressor.

QuickTime::GetDSequenceScreenBuffer

Returns:
a QDGraphics object which is the graphics world for the screen buffer

ptInData

public boolean ptInData(EncodedImage data,
                        QDPoint where)
                 throws StdQTException
Tests to see if an image contains data at a given point.

QuickTime::PtInDSequenceData

Parameters:
data - encoded image data
where - a Point object, (0,0) is upper left corner of the image
Returns:
true if the compressed data contains data at the point specified by the where parameter. false if the specified point falls within a blank portion of the image.

hitTestData

public boolean hitTestData(EncodedImage data,
                           QDPoint where,
                           int hitFlags)
                    throws StdQTException
The HitTestDSequenceData function allows the calling application to perform hit testing on compressed data.

QuickTime::HitTestDSequenceData

Parameters:
data - compressed data in the format specified by the description of the DSequence.
where - A QuickDraw Point (0,0) based at the top-left corner of the image.
hitFlags - indicates the hit-testing behaviour that is sought
Returns:
true if the compressed data contains data at the point specified by the where parameter.

flush

public void flush()
           throws StdQTException
Stops a decompression sequence, aborting processing of any queued frames.

QuickTime::CDSequenceFlush


invalidate

public void invalidate(Region invalRgn)
                throws StdQTException
Notifies the Image Compression Manager that the destination port for the given image decompression sequence has been invalidated.

QuickTime::CDSequenceInvalidate

Parameters:
invalRgn - a Region describing the invalid portion of the image

shieldCursor

public void shieldCursor()
                  throws StdQTException
Hides the cursor during decompression operations.

QuickTime::ICMShieldSequenceCursor


setTimeCode

public void setTimeCode(TimeCodeDef timeCodeFormat,
                        TimeCodeTime timeCodeTime)
                 throws StdQTException
Sets the timecode value for the frame that is about to be decompressed.

QuickTime__SetDSequenceTimeCode
Parameters:
You - provide the appropriate timecode definition information for the next frame to be decompressed.
You - provide the appropriate time value for the next frame in the current sequence.