Seamlessly change video stream while playing

Christophe Dongieux christophe.dongieux at gmail.com
Fri Jun 24 01:17:54 PDT 2011


Hello,

I'm currently developing a source plugin that gets ISO MP4 streams from a
server. These streams are the same video, but with different
bitrate/resolution, hence different quality.
I need to be able to change the stream quality, seamlessly, while the
gstreamer pipeline is playing.
The typical pipeline looks like this:
              source ! qtdemux ! ffdec_h264 ! ffmpegcolorspace ! xvimagesink

I already tried 2 solutions for the change to take effect, but with no luck:
1/ send the new MP4 file header (ftyp+moov boxes), then the movie fragments
(moof+mdat boxes). The problem is that qtdemux thinks it's a new video
stream, hence creates a new source video pad.
2/ don't send the new MP4 header, simply send the new movie fragments. Nor
qtdemux or ffdec_h264 notice the change, ffdec_h264 produces decoding
errors, the output video is scrambled.

Do you have any idea how I can achieve this?

Cheers,
Christophe Dongieux.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20110624/b4837095/attachment.html>


More information about the gstreamer-devel mailing list