net.sf.fmj.media.protocol.rtp
Class LookAheadPushBufferStream

java.lang.Object
  extended by net.sf.fmj.media.protocol.rtp.LookAheadPushBufferStream
All Implemented Interfaces:
Controls, PushBufferStream, SourceStream

public class LookAheadPushBufferStream
extends java.lang.Object
implements PushBufferStream

Looks ahead in the RTP PushBufferStream to fill in details of the VideoFormat, particularly the resolution. Only supports JPEG/RTP.

Author:
Ken Larson

Field Summary
 
Fields inherited from interface javax.media.protocol.SourceStream
LENGTH_UNKNOWN
 
Constructor Summary
LookAheadPushBufferStream(PushBufferStream s)
           
 
Method Summary
 boolean endOfStream()
           
 ContentDescriptor getContentDescriptor()
           
 long getContentLength()
           
 java.lang.Object getControl(java.lang.String controlType)
           
 java.lang.Object[] getControls()
           
 Format getFormat()
           
 void lookAheadAndFindFullFormat()
           
 void read(Buffer buffer)
           
 void setTransferHandler(BufferTransferHandler transferHandler)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LookAheadPushBufferStream

public LookAheadPushBufferStream(PushBufferStream s)
Method Detail

lookAheadAndFindFullFormat

public void lookAheadAndFindFullFormat()
                                throws java.lang.InterruptedException
Throws:
java.lang.InterruptedException

endOfStream

public boolean endOfStream()
Specified by:
endOfStream in interface SourceStream

getContentDescriptor

public ContentDescriptor getContentDescriptor()
Specified by:
getContentDescriptor in interface SourceStream

getContentLength

public long getContentLength()
Specified by:
getContentLength in interface SourceStream

getControl

public java.lang.Object getControl(java.lang.String controlType)
Specified by:
getControl in interface Controls

getControls

public java.lang.Object[] getControls()
Specified by:
getControls in interface Controls

getFormat

public Format getFormat()
Specified by:
getFormat in interface PushBufferStream

read

public void read(Buffer buffer)
          throws java.io.IOException
Specified by:
read in interface PushBufferStream
Throws:
java.io.IOException

setTransferHandler

public void setTransferHandler(BufferTransferHandler transferHandler)
Specified by:
setTransferHandler in interface PushBufferStream