[vls-devel] [PATCH] Rewrite of mpeg/ps2ts.cpp

Andrew de Quincey adq_dvb at lidskialf.net
Mon Aug 11 18:14:19 CEST 2003


Hi, I was trying to use vls to multicast an MPEG2-ps stream and ran into lots 
of problems. Investigating the code showed many issues, so I decided to 
rewrite it to fix them.

This patch fixes/adds the following features:

1) --loop on file inputs now works.

2) ps2ts now copes with PS with Program map tables in them.

I decided it wasn't actually worth parsing the program map itself as then you 
can't get the private stream ids for encapsulated MPEG1 streams... so I just 
made it skip PMTs correctly.

3) Lookahead removed to fix end-of-file issues.

4) All potential buffer overflows and the like removed... well _maybe_ :). If 
anyone spots something I've missed, please tell me....

5) Code should cope with duff MPEG files... streams ending too soon etc.

6) ps2ts now supports looping correctly.

I had to add support to the reader code to allow support for looping... but 
what I've added should not interfere with other parts of the system which do 
not know about the enhancements.

7) Various other potential issues (e.g. duff data from preparsing) removed by 
adding explicit support to ps2ts.

8) ps2ts _should_ now be much more robust.

Phew!

Theres probably a few others I've forgotten about in the meantime. All this 
should be back-compatable with the rest of the system.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vls-cvs-ps2ts.patch
Type: text/x-diff
Size: 40895 bytes
Desc: not available
Url : http://mailman.videolan.org/pipermail/vls-devel/attachments/20030811/f0505e3a/attachment.patch 


More information about the vls-devel mailing list