[vlc-devel] [PATCH] fix mux functionality, avoid dumping all ES in first PMT

Marnik Vander Elst marnik at marnik.org
Thu Jul 24 14:04:20 CEST 2008

Look for the ID specified in config in the PMT map, not for the
original incoming PID.

The code specifies that ts-es-id-pid should be used, so that the PMT
mapping can be done by the ID's. I printed out the PMT maps, and the
correct settings are loaded as specified with muxpmt and program-pmt.
However, all the ES are dumped in the first PMT because vlc searches
for the incoming pids instead of the id's, so they are not found. The
patch seems to fix this, but I'm not too sure why, I got lost in all
the ID's and PID's and structs and whatnot.

Config used:

del all

new stream1 broadcast enabled
new stream2 broadcast enabled
new stream3 broadcast enabled

setup stream1 input "udp://"
setup stream2 input "udp://"
setup stream3 input "udp://"

setup stream1 output
setup stream2 output
setup stream3 output

setup stream3 option sout-ts-tsid=55
setup stream3 option sout-ts-netid=88
setup stream3 option sout-ts-program-pmt="4000,4100,4200"
setup stream3 option sout-ts-muxpmt="1000,1100,,2000,2100,,1331,1332"
setup stream3 option
setup stream3 option sout-ts-es-id-pid
setup stream3 option sout-ts-pcr=35

control stream1 play
control stream2 play
control stream3 play


vlc -I telnet --vlm-conf mux.conf

Result in DVB analyser:


Some explanation with the screenshot:

PID 1000,1100,2000 and 2100 are correctly mapped in the right PMT's. I
do not find a way to set the id's for the third stream however, if i
use the same as the lines before than nothing happens:

setup stream1 output
setup stream2 output
setup stream3 output

Does not work, if I use bridge-out and bridge-in on the same line vlc
simply does nothing. As you can see, pid 1331 and 1332 are also
correctly mapped to the third service, but 1331 and 1332 are the
_input_ pids of the UDP-stream.

I hope that was somehow understandable, otherwise I'd be happy to give
more information.

Kind regards,


More information about the vlc-devel mailing list