From: Reinhard N. <rn...@gm...> - 2006-01-31 22:31:01
|
Hi, Thibaut Mattern wrote: >>>> ffmpeg switches to mpeg1/2 decoding mode only when analyzing preview >>>> buffers (see ff_handle_preview_buffer in libffmpeg/video_decoder.c). >>>> >>>> After a call to _x_demux_flush_engine(), ffmpeg doesn't switch to >>>> mpeg1/2 mode as no preview buffers are sent respectively received by ffmpeg. >>>> >>>> Are there any concerns about moving this detection to ff_decode_data(), >>>> so that any buffer (not just preview ones) can switch to mpeg1/2 mode >>>> and back? >>> >>> Sounds strange, why do you need to switch to mpeg12 mode on the fly? >> >> Because the video data is not MPEG4. > > IMHO it's a video decoder loop problem, it would be cleaner and more > powerful to handle this problem at the loop level. This will allow you > to decode mpeg2 with libmpeg2 and mpeg4 with ffmpeg. That would be nice, especially when VDR will once be able to process MPEG4 data. My reason for using ffmpeg to decode mpeg12 was that ffmpeg might support 4:2:2 video frames which libmpeg2 cannot handle. >>> If you have more than one video track, or if you need to change the >>> video decoder, then we have to implement that feature the same way >>> it's implemented for audio (backup header buffers, and detect buffer >>> type changes in the video loop). >> >> I'd appreciate such a solution. > > That's definitely the way to go. For sure ;-) Bye. -- Dipl.-Inform. (FH) Reinhard Nissl mailto:rn...@gm... |