public abstract class VideoEffect extends ThreadEventManager implements java.lang.Runnable
Constructor and Description |
---|
VideoEffect() |
Modifier and Type | Method and Description |
---|---|
void |
abort()
Aborts the processing of the video effect.
|
void |
addVideoEffectListener(IVideoEffectListener pVideoEffectListener)
Adds a video effect listener object and adds it also as thread listener.
|
void |
addVideoEffectListener(IVideoEffectListener pVideoEffectListener,
int iPosition)
Adds a video effect listener object and adds it also as thread listener at the specified position.
|
protected void |
fireProcessingStarted()
Notifies all listeners that the processing of the video effect has been started.
|
protected void |
fireSetCurrentVideoFrame(java.awt.image.BufferedImage pCurrentFrame,
int iFrameId,
int iFrameNumber)
Sets the current effect frame, which can be retrieved afterwards by the getCurrentFrame method, and
communicates the current status of the video effect to all
registered listeners.
|
java.awt.image.BufferedImage |
getCurrentFrame()
Returns the current frame that is processed.
|
int |
getPosition()
Returns the current frame id that is processed.
|
IVideo |
getVideo()
Returns the video object that should be processed.
|
void |
goToFirstFrame()
Sets the video back to the start.
|
void |
goToLastFrame()
Sets the video to the last frame.
|
void |
goToNextFrame()
Sets the video to the next available frame.
|
void |
goToPreviousFrame()
Sets the video to the previous frame.
|
boolean |
isVideoEffectAborted()
Returns true if the processing of the video effect got aborted.
|
abstract void |
process()
The actual processing method of the video effect that has to be implemented by each
video effect class.
|
void |
removeAllVideoEffectListeners()
Removes all video effect listeners.
|
void |
removeThreadListener(IVideoEffectListener pVideoEffectListener)
Removes the specified video effect listener.
|
void |
run()
Starts the processing of the video effect.
|
void |
setVideo(IVideo pVideo)
Sets the
IVideo object which should be processed by the VideoEffect object. |
addThreadListener, addThreadListener, fireEndedProperlyEvent, fireInterruptedEvent, fireProgressStatusEvent, removeAllThreadListeners, removeThreadListener
public void addVideoEffectListener(IVideoEffectListener pVideoEffectListener)
pVideoEffectListener
- The video effect listener that should be added.public void addVideoEffectListener(IVideoEffectListener pVideoEffectListener, int iPosition)
pVideoEffectListener
- The video effect listener that should be added.iPosition
- The position where the video effect listener should be added.public void removeThreadListener(IVideoEffectListener pVideoEffectListener)
pVideoEffectListener
- The video effect listener object that should be removed.public void removeAllVideoEffectListeners()
protected void fireSetCurrentVideoFrame(java.awt.image.BufferedImage pCurrentFrame, int iFrameId, int iFrameNumber)
VideoEffect
class.pCurrentFrame
- The current frame as BufferedImage
object.iFrameId
- The current frame id as integer.iFrameNumber
- The total number of frames as integer.protected void fireProcessingStarted()
VideoEffect
class.public void setVideo(IVideo pVideo)
IVideo
object which should be processed by the VideoEffect
object.pVideo
- The IVideo
object which represents the frames of the original video.public java.awt.image.BufferedImage getCurrentFrame()
BufferedImage
object.public int getPosition()
public IVideo getVideo()
public boolean isVideoEffectAborted()
public void abort()
public void run()
run
in interface java.lang.Runnable
public void goToFirstFrame()
public void goToLastFrame()
public void goToNextFrame()
public void goToPreviousFrame()
public abstract void process()