[Live-devel] MP Demux doubt (more details)

Woods woods.biz at gmail.com
Tue Jul 28 02:13:35 PDT 2009


Dear all,

I am writing a MP4Demux and MP4DemuxedElementaryStream, in way as
MPEG1or2Demux and MPEG1or2DemuxedElementaryStream. In specific, my MP4Demux
uses FFMPEG to read AVPacket from MP4 file, and feed the Packet->data to
MP4DemuxedElementaryStream. I tested my code in following ways, with
different results:

Audio based test:

(1) Only getAudioStream() from my MP4DemuxedElementaryStream (I set
presentation time stamp here according to AVPacket's pts value) and feed the
stream to BasicUDPSink as source. In this way, the streamed audio can be
perfectly replayed on my vlc player.
(2) Still getAudioStream() from my MP4DemuxedElementarystream, but this time
feed it to MPEGTransportStreamFromESStream + MPEG2TransportStreamFramer +
BasicUDPSink. This time the program reads through the input mp4 file very
fast without correct delaying between audio frames. Of course, this stream
is not playable on vlc. Why so, even though (as I mentioned in test 1) the
presentation Time is set correctly?

Video based test (this is a mess):
No matter I use BasicUDPSink nor
MPEGTransportStreamFromESStream+MPEG2TransportStreamFramer+BasicUDPSink, the
stream is not playable on vlc player. But when I only use BasicUDPSink, the
delaying between video frames is correct. But in both cases, the streamed
video is recognized by VLC. I even record those video packets to be sent as
a .m4e file, which is still not playable on vlc. So I want know is the
extracted AVPacket the wanted video elementary packets? Can they be used to
feed liveMedia classes as I described?

I have tried this code for 2 weeks, no more idea now. :-(

I will appreciate if someone could give me suggestion on this! Thank you
very much.


-- 
Woods
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20090728/87d38464/attachment.html>


More information about the live-devel mailing list