jfract V1.0a

org.jfract.util
Class MovieBuilder.ImageDataSource

java.lang.Object
  |
  +--javax.media.protocol.DataSource
        |
        +--javax.media.protocol.PullBufferDataSource
              |
              +--org.jfract.util.MovieBuilder.ImageDataSource
All Implemented Interfaces:
javax.media.Controls, javax.media.protocol.Controls, javax.media.Duration
Enclosing class:
MovieBuilder

class MovieBuilder.ImageDataSource
extends javax.media.protocol.PullBufferDataSource

A DataSource to read from a list of JPEG image files and turn that into a stream of JMF buffers. The DataSource is not seekable or positionable.


Field Summary
(package private)  MovieBuilder.ImageSourceStream[] streams
           
 
Fields inherited from class javax.media.protocol.DataSource
sourceLocator
 
Fields inherited from interface javax.media.Duration
DURATION_UNBOUNDED, DURATION_UNKNOWN
 
Constructor Summary
(package private) MovieBuilder.ImageDataSource(int width, int height, int frameRate, java.util.Vector images)
           
 
Method Summary
 void connect()
           
 void disconnect()
           
 java.lang.String getContentType()
          Content type is of RAW since we are sending buffers of video frames without a container format.
 java.lang.Object getControl(java.lang.String type)
           
 java.lang.Object[] getControls()
           
 javax.media.Time getDuration()
          We could have derived the duration from the number of frames and frame rate.
 javax.media.MediaLocator getLocator()
           
 javax.media.protocol.PullBufferStream[] getStreams()
          Return the ImageSourceStreams.
 void setLocator(javax.media.MediaLocator source)
           
 void start()
           
 void stop()
           
 
Methods inherited from class javax.media.protocol.DataSource
initCheck
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 
Methods inherited from interface javax.media.Duration
 

Field Detail

streams

MovieBuilder.ImageSourceStream[] streams
Constructor Detail

MovieBuilder.ImageDataSource

MovieBuilder.ImageDataSource(int width,
                             int height,
                             int frameRate,
                             java.util.Vector images)
Method Detail

setLocator

public void setLocator(javax.media.MediaLocator source)
Overrides:
setLocator in class javax.media.protocol.DataSource

getLocator

public javax.media.MediaLocator getLocator()
Overrides:
getLocator in class javax.media.protocol.DataSource

getContentType

public java.lang.String getContentType()
Content type is of RAW since we are sending buffers of video frames without a container format.
Overrides:
getContentType in class javax.media.protocol.DataSource

connect

public void connect()
Overrides:
connect in class javax.media.protocol.DataSource

disconnect

public void disconnect()
Overrides:
disconnect in class javax.media.protocol.DataSource

start

public void start()
Overrides:
start in class javax.media.protocol.DataSource

stop

public void stop()
Overrides:
stop in class javax.media.protocol.DataSource

getStreams

public javax.media.protocol.PullBufferStream[] getStreams()
Return the ImageSourceStreams.
Overrides:
getStreams in class javax.media.protocol.PullBufferDataSource

getDuration

public javax.media.Time getDuration()
We could have derived the duration from the number of frames and frame rate. But for the purpose of this program, it's not necessary.
Overrides:
getDuration in class javax.media.protocol.DataSource

getControls

public java.lang.Object[] getControls()
Overrides:
getControls in class javax.media.protocol.DataSource

getControl

public java.lang.Object getControl(java.lang.String type)
Overrides:
getControl in class javax.media.protocol.DataSource

jfract V1.0a

Generee le 27.09.2002 08:21:59 PM