[MPlayer-dev-eng] Transport Stream demuxer help
Nico
nsabbi at libero.it
Sun Feb 16 21:43:50 CET 2003
Arpi wrote:
>you shouldn't mix the raw and mpeg demuxer sthis way, imho
>new_demuxers_demuxer(od,od,od) is the right line.
>
>but anyway i would use instead of the above:
>
> // assuming demuxer->type == DEMUXER_TYPE_MPEG_TS and that you
> // write PS packets to the video queue of 'demuxer'
> s = new_ds_stream(demuxer->video);
> return demux_open_stream(s,DEMUXER_TYPE_MPEG_PS,-1,-1,-1,NULL);
>
>maybe write 0 (or (PS! not the TS!) stream id) instead of -1.
>
>
>
This way it segfaults, but if I do:
sh_video = new_sh_video(demuxer, 0);
sh_video->ds = demuxer->video;
demuxer->video->sh = sh_video;
// the same for audio, but I never fill that stream
s = new_ds_stream(demuxer->video);
return demux_open_stream(s, DEMUXER_TYPE_MPEG_PS, -1, -1, -1, NULL);
I can see video files correctly.
If there is audio, and I pipe it in the same fifo (video) the PS demuxer
doesn't recognize it, and garbles the video.
What's the best way to make both work? I guess I have to output the
packets in some particular order to make the PS demuxer recognize the
stream as PS and not ES, but how?
Is it possible to seek using this pipelined demuxer?
A last note: I'm a little confused on how demux_mpg names the various
streams:
- it names ES what has PES headers (000001Cn or En) + ES data
(shouldn't it be called PES stream)?
- what's the difference between MPEG-PS and -PES?
Thanks,
Nico
More information about the MPlayer-dev-eng
mailing list