Package com.avpkit.mediatool.demos
Class DecodeAndPlayAudioAndVideo
- java.lang.Object
-
- com.avpkit.mediatool.AMediaListenerMixin
-
- com.avpkit.mediatool.MediaListenerAdapter
-
- com.avpkit.mediatool.demos.DecodeAndPlayAudioAndVideo
-
- All Implemented Interfaces:
IMediaListener
public class DecodeAndPlayAudioAndVideo extends MediaListenerAdapter
UsingIMediaReader, takes a media container, finds the first video stream, decodes that stream, and then plays the audio and video.- Author:
- aclarke, trebor
-
-
Constructor Summary
Constructors Constructor Description DecodeAndPlayAudioAndVideo()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidmain(java.lang.String[] args)Takes a media container (file) as the first argument, opens it, plays audio as quickly as it can, and opens up a Swing window and displays video frames with roughly the right timing.-
Methods inherited from class com.avpkit.mediatool.MediaListenerAdapter
onAddStream, onAudioSamples, onClose, onCloseCoder, onFlush, onOpen, onOpenCoder, onReadPacket, onVideoPicture, onWriteHeader, onWritePacket, onWriteTrailer
-
-
-
-
Constructor Detail
-
DecodeAndPlayAudioAndVideo
public DecodeAndPlayAudioAndVideo()
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
Takes a media container (file) as the first argument, opens it, plays audio as quickly as it can, and opens up a Swing window and displays video frames with roughly the right timing.- Parameters:
args- Must contain one string which represents a filename
-
-