[FFmpeg-user] On Demand Input Switching

me at renecalles.de me at renecalles.de
Thu Apr 19 14:37:27 CEST 2012


Hi Andrey,

thanks a lot for your helpful answer.
I'm just not shure how buffering could work for seamless switching.
I think i would need to preserve the latest frame for live source and 
first frame from file source, encode them properly to the output format 
and serve the "Playout/Muxer"-Module.

So, it seems i have to use multiple instances of Framebuffers??? for a 
seamless switch.

Am i right here?

Anyway it seems then i have to move to the libav-dev list.

Thanks a lot.

René



On Thu, 19 Apr 2012 11:21:56 +0300, Andrey Utkin wrote:
> 2012/4/18  <me at renecalles.de>:
>> If it is not possible to do it with FFmpeg, could someone please 
>> point me
>> into a direction how such process could be accomplished 
>> programmatically?
>
> FFMpeg util is not capable of this, afaik.
> Programmatically, with ffmpeg API - quite possible, i have an
> experience on this.
> Generally, you can just get media from any sources you need, and mix
> them as you wish, the point is that you must feed to output encoding
> and muxing contexts the media that has consistent characteristics. I.
> e.:
> 1. Elementary streams quantity and characteristics mustn't change
> (look out for cases when there are several audio tracks in container,
> for example);
> 2. Video format, and its "extradata" (global header, if present)
> mustn't change (thus you almost certainly must transcode);
> 3. Video picture dimensions must stay same (thus very probable you
> must resize, using libavfilter for that is handy);
> 4. Also i think if there is certain video frame rate, then you should
> preserve it.
> 5. Audio format, channels layout (mono/stereo/etc), sample rate must
> stay same.
>
> I hope i ended up with not so many wrong points or bad explanations,
> corrections are appreciated.



More information about the ffmpeg-user mailing list