|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--quicktime.app.players.MoviePlayer
The MoviePlayer class allows your application to display, play and control any
QuickTime movie. The MoviePlayer
object works with the QTCanvas to be displayed in a Java AWT Container.
QTCanvas
,
Movie
Fields inherited from interface quicktime.app.players.Playable |
kDurationUnknown |
Constructor Summary | |
MoviePlayer(Movie mov)
This constructor creates a MoviePlayer object given a QuickTime Movie object. |
Method Summary | |
void |
addDrawingListener(DrawingListener listener)
Registers an object as a listener of the MoviePlayer. |
void |
addedTo(java.lang.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. |
Region |
getClip()
This method allows you to obtain information describing a MoviePlayer's clipping regions. |
QDRect |
getDisplayBounds()
This method is called automatically via the QTCanvas object associated with this client to set the boundary of the movie. |
int |
getDuration()
Returns the duration of the media attached to the player. |
QDGraphics |
getGWorld()
QTCanvas calls this method to get the destination QDGraphics of its client. |
java.awt.Dimension |
getInitialSize()
Deprecated. since QTJava 4.0 |
Matrix |
getMatrix()
This will return the client's current display transformations |
Movie |
getMovie()
This allows you to access the contained movie controller. |
QDDimension |
getOriginalSize()
This method returns the original size before the transformations specified in the returned matrix are applied. |
float |
getRate()
Returns the current rate of the player. |
int |
getScale()
Returns the time scale of the player - how many ticks per second. |
int |
getTime()
Returns the current time value of the object. |
TimeBase |
getTimeBase()
Returns the TimeBase of the media attached to the player. |
float |
getVolume()
Returns the volume setting (0 is silent, 1 is unity gain). |
boolean |
isMuted()
Returns the current mute status. |
void |
redraw(Region invalidRgn)
QTCanvas calls this method when the client should redraw itself. |
void |
removedFrom(java.lang.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. |
void |
removeDrawingListener(DrawingListener listener)
Removes an object that is a listener of the MoviePlayer. |
void |
setClip(Region theClip)
This method allows you to set a MoviePlayer's clipping region. |
void |
setDisplayBounds(QDRect bounds)
This method is called automatically via the QTCanvas object associated with this client to set the boundary of the movie. |
void |
setGWorld(QDGraphics cgp)
QTCanvas calls this method to give the client the QDGraphics object it should use to do its drawing. |
void |
setLocation(int x,
int y)
A convenience method to set the position of a QTDrawable object. |
void |
setMatrix(Matrix matrix)
This method sets the current matrix of the Transformable object to the new matrix. |
void |
setMuted(boolean flag)
Allows the muting of the specific channel. |
void |
setRate(float rate)
Sets the player to the playback rate. |
void |
setTime(int time)
Sets the player to the time specified. |
void |
setVolume(float val)
Sets the volume. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MoviePlayer(Movie mov) throws StdQTException
mov
- a Movie objectMethod Detail |
public Movie getMovie()
public void addedTo(java.lang.Object interest)
addedTo
in interface Listener
interest
- the object that is to be the source of interest for the
the object that implements this interface.public void removedFrom(java.lang.Object interest)
removedFrom
in interface Listener
interest
- the object that was the source of interest for the
the object that implements this interface.public QDGraphics getGWorld() throws StdQTException
getGWorld
in interface QTDrawable
public void setGWorld(QDGraphics cgp) throws StdQTException
setGWorld
in interface QTDrawable
cgp
- a QDGraphics objectpublic java.awt.Dimension getInitialSize() throws QTException
()
public QDDimension getOriginalSize() throws QTException
getOriginalSize
in interface Transformable
public Matrix getMatrix() throws StdQTException
getMatrix
in interface Transformable
public void setMatrix(Matrix matrix) throws QTException
setMatrix
in interface Transformable
public final void redraw(Region invalidRgn) throws QTException
redraw
in interface Drawable
invalidRgn
- the invalidRgn that the client should redrawpublic void setDisplayBounds(QDRect bounds) throws StdQTException
setDisplayBounds
in interface Drawable
bounds
- a QDRect object describing the boundarypublic void setLocation(int x, int y) throws QTException
setLocation
in interface QTDrawable
x
- the new x locationy
- the new y locationpublic QDRect getDisplayBounds() throws StdQTException
getDisplayBounds
in interface Drawable
bounds
- a QDRect object describing the boundarypublic void setClip(Region theClip) throws QTException
setClip
in interface QTDrawable
theClip
- a Region that defines the player's clipping region.public Region getClip() throws QTException
getClip
in interface QTDrawable
public void setTime(int time) throws StdQTException
setTime
in interface Playable
time
- the new time valuepublic int getTime() throws StdQTException
getTime
in interface Playable
public int getDuration() throws StdQTException
getDuration
in interface Playable
public TimeBase getTimeBase() throws QTException
getTimeBase
in interface Timeable
public void setRate(float rate) throws StdQTException
setRate
in interface Timeable
rate
- the new playback rate.public void addDrawingListener(DrawingListener listener)
addDrawingListener
in interface DrawingNotifier
quicktime.app.display.DrawingNotifier
source
- the object that is to be the source of interest for the
the Listener object.public void removeDrawingListener(DrawingListener listener)
removeDrawingListener
in interface DrawingNotifier
quicktime.app.display.DrawingNotifier
source
- the object that is to be the source of interest for the
the Listener object.public float getRate() throws StdQTException
getRate
in interface Timeable
public int getScale() throws QTException
getScale
in interface Playable
public float getVolume() throws QTException
getVolume
in interface AudioSpec
public void setVolume(float val) throws QTException
setVolume
in interface AudioSpec
val
- the new volumepublic boolean isMuted() throws QTException
isMuted
in interface AudioSpec
public void setMuted(boolean flag) throws QTException
setMuted
in interface AudioSpec
flag
- turn muting on - true or off - false.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |