com.sun.media
类 ProcessEngine

java.lang.Object
  继承者 com.sun.media.BasicController
      继承者 com.sun.media.PlaybackEngine
          继承者 com.sun.media.ProcessEngine
所有已实现的接口:
ModuleListener, Clock, Controller, Duration

public class ProcessEngine
extends PlaybackEngine

ProcessEngine implements the media engine for processors.


字段摘要
protected  BasicMuxModule muxModule
           
protected  javax.media.protocol.ContentDescriptor outputContentDes
           
protected  com.sun.media.GraphNode targetMux
           
protected  com.sun.media.GraphNode[] targetMuxes
           
protected  Format[] targetMuxFormats
           
protected  java.util.Vector targetMuxNames
          This is the Graph builder to generate the data flow graph for the media engine.
 
从类 com.sun.media.PlaybackEngine 继承的字段
bitRateControl, container, dsource, filters, framePositioningControl, frameRateControl, genericProcessorError, jmd, masterSink, modules, needSavingDB, parser, player, prefetched, prefetchEnabled, progressControl, realizeError, sinks, slaveClock, source, started, timeBaseError, TRACE_ON, trackControls, tracks, waitEnded, waitPrefetched, waitResetted, waitStopped
 
从类 com.sun.media.BasicController 继承的字段
processError, state, stopThreadEnabled
 
从接口 javax.media.Controller 继承的字段
LATENCY_UNKNOWN, Prefetched, Prefetching, Realized, Realizing, Started, Unrealized
 
从接口 javax.media.Clock 继承的字段
RESET
 
从接口 javax.media.Duration 继承的字段
DURATION_UNBOUNDED, DURATION_UNKNOWN
 
构造方法摘要
ProcessEngine(BasicProcessor p)
           
 
方法摘要
protected  boolean doConfigure()
          Configuring the engine.
protected  boolean doPrefetch()
          The stub function to perform the steps to prefetch the controller.
protected  boolean doRealize()
          The stub function to perform the steps to realize the controller.
protected  void doStart()
          Start immediately.
protected  void doStop()
          Invoked from stop().
protected  BasicSinkModule findMasterSink()
          Search and update the master time base.
protected  long getBitRate()
          Report the output bit rate if a mux is used.
 javax.media.protocol.ContentDescriptor getContentDescriptor()
          Return the output content-type.
 javax.media.protocol.DataSource getDataOutput()
          Return the output DataSource of the Processor.
protected  PlugIn getPlugIn(BasicModule m)
          Get the plugin from a module.
 javax.media.protocol.ContentDescriptor[] getSupportedContentDescriptors()
          Return all the content-types which this Processor's output supports.
 javax.media.control.TrackControl[] getTrackControls()
          Get the track controls.
protected  void resetBitRate()
           
 javax.media.protocol.ContentDescriptor setContentDescriptor(javax.media.protocol.ContentDescriptor ocd)
          Set the output content-type.
 
从类 com.sun.media.PlaybackEngine 继承的方法
abortConfigure, abortPrefetch, abortRealize, audioEnabled, bufferPrefetched, buildTrackFromGraph, connectModules, createModule, createProgressControl, createVisualContainer, dataBlocked, doClose, doConfigure1, doConfigure2, doDeallocate, doFailedPrefetch, doFailedRealize, doPrefetch1, doPrefetch2, doRealize1, doRealize2, doReset, doSetMediaTime, doSetRate, doStart1, doStart2, doStop1, doStop2, formatChanged, formatChangedFailure, framesBehind, getCNAME, getControls, getDuration, getGainControl, getLatency, getStartLatency, getTimeBase, getVisualComponent, internalErrorOccurred, isConfigurable, isRTP, lastModule, localStop, markedDataArrived, mediaEnded, pluginTerminated, reset, resetted, setMediaTime, setMemoryTrace, setProgressControl, setRenderBufferSize, setSource, setStopTime, setTimeBase, stop, stopAtTime, updateFormats, updateRates, videoEnabled
 
从类 com.sun.media.BasicController 继承的方法
addControllerListener, close, completeConfigure, completePrefetch, completeRealize, configure, deallocate, dispatchEvent, doFailedConfigure, getClock, getControl, getMediaNanoseconds, getMediaTime, getRate, getState, getStopTime, getSyncTime, getTargetState, interrupt, isInterrupted, mapToTimeBase, prefetch, realize, removeControllerListener, resetInterrupt, sendEvent, setClock, setMediaLength, setRate, setTargetState, stopAtTime, stopControllerOnly, syncStart, syncStartInProgress, throwError
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

muxModule

protected BasicMuxModule muxModule

outputContentDes

protected javax.media.protocol.ContentDescriptor outputContentDes

targetMuxNames

protected java.util.Vector targetMuxNames
This is the Graph builder to generate the data flow graph for the media engine. It extends from the SimpleGraphBuilder to handle multiplexers, customized output formats, codecs and renderers. It contains 3 parts: 1) Routines to search for all the supported output formats; 2) Routines to build a default flow graph -- buildGraph; 3) Routines to build a custom flow graph -- buildCustomGraph. A default graph is such that no customised option is specified on the TrackControl.


targetMuxes

protected com.sun.media.GraphNode[] targetMuxes

targetMux

protected com.sun.media.GraphNode targetMux

targetMuxFormats

protected Format[] targetMuxFormats
构造方法详细信息

ProcessEngine

public ProcessEngine(BasicProcessor p)
方法详细信息

doConfigure

protected boolean doConfigure()
Configuring the engine.

覆盖:
PlaybackEngine 中的 doConfigure

doRealize

protected boolean doRealize()
从类 BasicController 复制的描述
The stub function to perform the steps to realize the controller. Call realize() for the public method. This is called from a separately running thread. So do take necessary precautions to protect shared resources. It's OK to put an empty stub function body here.

Return true if the realize is successful. Return false and set the processError string if failed.

This function is not declared synchronized because first it is already guaranteed by realize() not to be called more than once simultaneously. Secondly if this is synchronized, then other synchronized methods, deallocate() and processEvent() will be blocked since they are synchronized methods. Override this to implement subclass behavior.

覆盖:
PlaybackEngine 中的 doRealize
返回:
true if successful.

findMasterSink

protected BasicSinkModule findMasterSink()
Search and update the master time base.

覆盖:
PlaybackEngine 中的 findMasterSink

doPrefetch

protected boolean doPrefetch()
The stub function to perform the steps to prefetch the controller.

覆盖:
PlaybackEngine 中的 doPrefetch
返回:
true if successful.

doStart

protected void doStart()
Start immediately. Invoked from start(tbt) when the scheduled start time is reached. Use the public start(tbt) method for the public interface. Override this to implement subclass behavior.

覆盖:
PlaybackEngine 中的 doStart

doStop

protected void doStop()
Invoked from stop(). Override this to implement subclass behavior.

覆盖:
PlaybackEngine 中的 doStop

getTrackControls

public javax.media.control.TrackControl[] getTrackControls()
                                                    throws NotConfiguredError
Get the track controls.

抛出:
NotConfiguredError

getSupportedContentDescriptors

public javax.media.protocol.ContentDescriptor[] getSupportedContentDescriptors()
                                                                        throws NotConfiguredError
Return all the content-types which this Processor's output supports.

抛出:
NotConfiguredError

setContentDescriptor

public javax.media.protocol.ContentDescriptor setContentDescriptor(javax.media.protocol.ContentDescriptor ocd)
                                                            throws NotConfiguredError
Set the output content-type.

抛出:
NotConfiguredError

getContentDescriptor

public javax.media.protocol.ContentDescriptor getContentDescriptor()
                                                            throws NotConfiguredError
Return the output content-type.

抛出:
NotConfiguredError

getDataOutput

public javax.media.protocol.DataSource getDataOutput()
                                              throws NotRealizedError
Return the output DataSource of the Processor.

抛出:
NotRealizedError

getBitRate

protected long getBitRate()
Report the output bit rate if a mux is used.

覆盖:
PlaybackEngine 中的 getBitRate

resetBitRate

protected void resetBitRate()
覆盖:
PlaybackEngine 中的 resetBitRate

getPlugIn

protected PlugIn getPlugIn(BasicModule m)
Get the plugin from a module. For debugging.

覆盖:
PlaybackEngine 中的 getPlugIn