[Libav-user] how to get extradata of MPEGTS using ffmpeg?

Licheng Niu niulicheng at gmail.com
Tue Sep 18 14:45:35 CEST 2012


Libstagefright doesn't support mpegts on some Android2.3 system. So I added
ffmpeg mpegts demuxer as an extra Extractor in stagefright.

For mp4 or flv files, I can read extradata in header(ffmpeg will do such
thing). But there is no header in TS file(I suspect). So how to get
extradata from TS file? It seems to be included in PESpacket but I am not
sure. I am not familiar with TS container.

Best Regards
Licheng Niu

On Tue, Sep 18, 2012 at 8:27 PM, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:

> Licheng Niu <niulicheng at ...> writes:
>
> > I am trying to decode TS file on android with
> > hardware decoder. And I use ffmpeg MPEGTS demuxer.
> > To init hardware decoder,
>
> (Isn't libstagefright supposed to do that? Or do I
> misunderstand?)
>
> > extradata (SPS, PPS or sth.) is needed to be set
> > for both audio and video decoders. But I can not
> > get extradata of TS file by ffmpeg demuxer.
>
> I suspect only the (software) h264 decoder is able
> to read the extradata from the video stream.
>
> Carl Eugen
>
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/libav-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20120918/d6e68d99/attachment.html>


More information about the Libav-user mailing list