The prog-map property of mpegtsmux only allows you to group pids together in a program. The program number set in the PAT/PMT tables cannot be set explicitly. This patch will set the program number according to the prog-map. If a program id of 0 is given, the first vacant program number starting from 1 will be used. https://bugzilla.gnome.org/show_bug.cgi?id=697239