240 likes | 384 Views
JMF Introduction. Yuqiang Liao 08-04-2006. Content. What can JMF do Handling Time-Based Media JMF Architecture Key components in JMF Processing time-based media Handling Real-Time Media Streams JMF Architecture Key components in JMF Processing stream media Exporting RTP streams
E N D
JMF Introduction Yuqiang Liao 08-04-2006
Content • What can JMF do • Handling Time-Based Media • JMF Architecture • Key components in JMF • Processing time-based media • Handling Real-Time Media Streams • JMF Architecture • Key components in JMF • Processing stream media • Exporting RTP streams • Extending custom plugins • Control Point for DRM Tool • SAV Architecture • Current issues • Resource
What can JMF do • The framework can be extended to present, capture, process and plug-in all kinds of media resource which are time-based or real-time-based • Media processing model
Key components in JMF • Clock syncs behaviors of many tracks • Player corresponding to each track manipulates track • Processor inherits from player can handle custom media through plugins • Event drives player/processor notify event-listener • Datasource represents media resource and datasink manipulates datasource, i.e. read/write datasource • Manager maintains several kinds of components, i.e Manager, PackageManager,PluginManager,CaptureManager
Processing Time-Based Media • Creating a Player • Setting kinds of parameters, i.e. playback rate • Starting player • Responding to Media Events • Synchronizing controllers • Stop player
Key components in JMF(RTP) • SessionManager is used to coordinate RTP session through supporting RTCP and to manipulate streams • RTPStream represents stream in RTP. Two types of RTP streams, ReceiveStream and SendStream • RTPEvent is used to report on the state of the RTP session and streams • Listener is used to react on events. Three types of stream listeners, SendStreamListener,ReceiveStreamListener,and RemoteListener • RTPData in JMF is PushBufferDataSource
Processing stream media • Setting up a RTP session • Detecting new data stream by NewReceiveStreamEvent • Retrieving stream by getDataSource • Creating a player for the RTP stream
Exporting RTP streams • Constructing a Processor to retrieve ReceiveStream • Setting the track formats to perform the desired encoding • Getting the output DataSource from the processor • Constructing an RTP file writer with the DataSource
Extending custom plugins • Custom plugins • Only processor handles plugins • Configuring processor • Calling PlugInManager.getPlugInList to determine what plug-ins are available • Calling getTrackControls on Processor to get a TrackControl for each track in stream • Calling the TrackControl setCodecChain or setRenderer to specify the plug-ins you want to use for each track • Implementing JMF Plug-ins seeing Chapter 6
Control Point for DRM Tool DRM Tool will be plugged into Pre-processing Effect point
SAV Architecture 1.Render browser 2.Interactive end-user 3.Render media content SAVRender 1.Parse DCI/DCF 2.Analysis right in license 3.Call JMF Engine SAVManager 1.Access CPD to render programs in embedded browser 2.Access LPD to acquire/query license via its protocol 3.Access CID to validate content ID via its protocol SAVMessanger DRM Processor 1.Load DRM Tool 2.More…? 1.Encrypt/Decrypt resource 2.More…? DRM Tool • Practice Play/Stop/Privous/Next/Volumn Controls • 2. Sink media resource (doubt is the type of resource?) • 3. Plugin DRM Tool • 4. Access RTP Server JMF Engine Green means module Orange means functionality
Current issues • JMF Can only handle URL of media resource(i.e. .mp3) so it could not handle .dcf directly • Answer: The media resource(i.e. Mp3) will be extracted to a temp folder • What’s the type of recorded resource? mp3 sth. like that or stream downloaded from RTP? • Record the resource as their own type • Encrypt/Decrypt resource on playing? • YES.
Player Glance Player States Glance
Resource • http://java.sun.com/products/java-media/jmf/ • JMF2.0 API Guide • http://www.javaworld.com/jw-04-2001/jw-0406-jmf1.html • http://forum.java.sun.com/forum.jspa?forumID=28&start=0