All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class quicktime.app.sg.SGDrawer

java.lang.Object
   |
   +----quicktime.app.time.Tasking
           |
           +----quicktime.app.sg.SGDrawer

public class SGDrawer
extends Tasking
implements QTDrawable
This class presents the SequenceGrabber/SGChannel component as a Drawable object so that it can be displayed within the confines of the QTCanvas.


Constructor Index

 o SGDrawer(SGVideoChannel)
This constructor creates an SGDrawer object from a SGChannel component.

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 getClip()
Returns a region that defines the current clipping region for the object.
 o getDisplayBounds()
Returns the current display location and size of the SGDrawer.
 o getGWorld()
QTCanvas calls this method to get the destination QDGraphics of its client.
 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 getSequenceGrabber()
This returns the SequenceGrabber that is presented by this drawable.
 o getSGChannel()
This returns the SequenceGrabber's VideoChannel that is presented by this drawable.
 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 setClip(Region)
Sets a region that will define the clipping region for the object
 o setDisplayBounds(QDRect)
Sets the display bounds for the SGDrawer
 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 method sets the current matrix of the Transformable object to the new matrix.
 o task()
This method performs idle processing for the SGDrawer and will be automatically called if this object is added to the TaskThread object.
 o toString()
Returns a String representation of this object.

Constructors

 o SGDrawer
 public SGDrawer(SGVideoChannel sg) throws QTException
This constructor creates an SGDrawer object from a SGChannel component. If the channel is set to useVideo then it will throw a paramErr QTException.

Parameters:
sg - the SequenceGrabber component channel to present.

Methods

 o getSGChannel
 public SGVideoChannel getSGChannel()
This returns the SequenceGrabber's VideoChannel that is presented by this drawable.

Returns:
an SGVideoChannel
 o getSequenceGrabber
 public SequenceGrabber getSequenceGrabber()
This returns the SequenceGrabber that is presented by this drawable.

Returns:
an SequenceGrabber
 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() throws StdQTException
QTCanvas calls this method to get the destination QDGraphics of its client.

Returns:
a QDGraphics object or null
 o setGWorld
 public synchronized 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 getInitialSize
 public Dimension getInitialSize() throws QTException
This method returns the original size before the transformations specified in the returned matrix are applied.

Returns:
the intial size of the SGDrawer
 o getMatrix
 public Matrix getMatrix() throws StdQTException
This will return the client's current display transformations

Returns:
the display transformations of the client
 o setMatrix
 public void setMatrix(Matrix matrix) throws QTException
This method sets the current matrix of the Transformable object to the new matrix.

Parameters:
matrix - the new display Matrix
 o setDisplayBounds
 public synchronized void setDisplayBounds(QDRect bounds) throws StdQTException
Sets the display bounds for the SGDrawer

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() throws StdQTException
Returns the current display location and size of the SGDrawer.

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 QTException
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 task
 public final synchronized void task() throws StdQTException
This method performs idle processing for the SGDrawer and will be automatically called if this object is added to the TaskThread object.

Overrides:
task in class Tasking
See Also:
TaskThread
 o toString
 public String toString()
Returns a String representation of this object.

Overrides:
toString in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index