com.smaxe.uv.client.video
Class AbstractVideo

java.lang.Object
  extended by com.smaxe.uv.client.video.AbstractVideo
All Implemented Interfaces:
IVideo
Direct Known Subclasses:
EmptyVideo, FlvVideo

public abstract class AbstractVideo
extends java.lang.Object
implements IVideo

AbstractVideo - abstract IVideo.

Version:
1.5.12
Author:
Andrei Sochirca
See Also:
JUV RTMP Client

Constructor Summary
AbstractVideo()
          Constructor.
 
Method Summary
 double bufferLength()
          Returns the number of seconds of data currently in the buffer.
 long bytesLoaded()
          Returns the number of bytes of data that have been loaded.
 long bytesTotal()
          Returns the total size in bytes of the file being loaded.
 void clear()
          Clears video state.
 void clearPlayBuffer()
          Clears video play buffer.
 double fps()
          Returns current fps.
 double liveDelay()
          Returns the number of seconds of data in the subscribing stream's buffer in live (unbuffered) mode.
 void onAudioData(MediaData data)
          Notifies about available audio frame.
 void onCuePoint(java.lang.Object data)
          Notifies about stream's cue point.
 void onFlvData(MediaData data)
          Notifies about available flv-data.
 void onMetaData(java.lang.Object data)
          Notifies about stream's metadata.
 void onSetDataFrame(java.lang.String method, java.lang.Object data)
          Notifies about "@setDataFrame" frame.
 void onVideoData(MediaData data)
          Notifies about available video frame.
 void reset()
          Resets video.
 double time()
          Returns the position of the playhead, in seconds.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractVideo

public AbstractVideo()
Constructor.

Method Detail

bufferLength

public double bufferLength()
Description copied from interface: IVideo
Returns the number of seconds of data currently in the buffer.

Specified by:
bufferLength in interface IVideo
Returns:
number of seconds of data currently in the buffer

bytesLoaded

public long bytesLoaded()
Description copied from interface: IVideo
Returns the number of bytes of data that have been loaded.

Specified by:
bytesLoaded in interface IVideo
Returns:
number of bytes of data that have been loaded

bytesTotal

public long bytesTotal()
Description copied from interface: IVideo
Returns the total size in bytes of the file being loaded.

Specified by:
bytesTotal in interface IVideo
Returns:
total size in bytes of the file being loaded

fps

public double fps()
Description copied from interface: IVideo
Returns current fps.

Specified by:
fps in interface IVideo
Returns:
current FPS

liveDelay

public double liveDelay()
Description copied from interface: IVideo
Returns the number of seconds of data in the subscribing stream's buffer in live (unbuffered) mode.

Specified by:
liveDelay in interface IVideo
Returns:
number of seconds of data in the subscribing stream's buffer in live (unbuffered) mode

time

public double time()
Description copied from interface: IVideo
Returns the position of the playhead, in seconds.

Specified by:
time in interface IVideo
Returns:
position of the playhead, in seconds

clear

public void clear()
Description copied from interface: IVideo
Clears video state.

Specified by:
clear in interface IVideo

clearPlayBuffer

public void clearPlayBuffer()
Description copied from interface: IVideo
Clears video play buffer.

Specified by:
clearPlayBuffer in interface IVideo

reset

public void reset()
Description copied from interface: IVideo
Resets video.

Specified by:
reset in interface IVideo

onAudioData

public void onAudioData(MediaData data)
Description copied from interface: IVideo
Notifies about available audio frame.

Note: This method should be really quick.

Specified by:
onAudioData in interface IVideo
Parameters:
data - audio data frame

onVideoData

public void onVideoData(MediaData data)
Description copied from interface: IVideo
Notifies about available video frame.

Note: This method should be really quick.

Specified by:
onVideoData in interface IVideo
Parameters:
data - video data frame

onFlvData

public void onFlvData(MediaData data)
Description copied from interface: IVideo
Notifies about available flv-data.

Note: This method should be really quick.

Specified by:
onFlvData in interface IVideo

onCuePoint

public void onCuePoint(java.lang.Object data)
Description copied from interface: IVideo
Notifies about stream's cue point.

Note: This method should be really quick.

Specified by:
onCuePoint in interface IVideo
Parameters:
data - cue-point data

onMetaData

public void onMetaData(java.lang.Object data)
Description copied from interface: IVideo
Notifies about stream's metadata.

Note: This method should be really quick.

Specified by:
onMetaData in interface IVideo
Parameters:
data - meta-data

onSetDataFrame

public void onSetDataFrame(java.lang.String method,
                           java.lang.Object data)
Description copied from interface: IVideo
Notifies about "@setDataFrame" frame.

Note: This method should be really quick.

Specified by:
onSetDataFrame in interface IVideo
Parameters:
method - method
data - meta-data