NullPacketStripper ================== Written by Oliver Wagner Copyright (C) 2003-2005, All Rights Reserved NullPacketStripper is a small utility designed to merge segments and remove null packets from MPEG 2 transport stream files received from a D-VHS deck. It can - automatically merge files following the filename.nnnn.ts (with nnnn being a 1-4 digit number) pattern - remove fill packets to heavily reduce storage requirement without sacrificing an iota of quality. Filtering by PID can be customized to extract specific streams out of multicast recordings. - deal with broken files by automatically resyncing to the next TS packet - optionally split output files at user selectable sizes - operate in a "multi volume mode" where files from several volumes (e.g. DVD-media) can be processed and - it's fast :) The GUI should be self-explanatory. NullPacketStripper is written in Java; to run it, you need to have a 1.4.x JVM installed; see http://java.sun.com/j2se/1.4.2/download.html and download the JRE (not SDK) for your platform. The Microsoft JVM which ships with Windows per default will NOT work. Comments are welcome, please mail to . Please note that I originally wrote this for my own use and am now releasing it for free in the hope that it might be useful to others. However, I do not give any kind of warranty, and I have no resources to provide any end-user support for it. Thanks to Jerome Fisher for his help in finding pieces of MPEG transport stream documentation, and to Nils Öllerer and Thomas Hötte for help during initial debugging and many useful suggestions. Revision history ---------------- 0.1 - Initial test version 0.2 - split capability, sanitized log messages a bit 0.3 - automatically fill in name of dest file when selecting source - changed input file pattern matching to skip "gaps" in the numbering sequencing - more statistics in output - fixed splitting to not always split upon a new input segment - 143MB split default changed to 137MB 0.4 - default unit for split sizes is now MB. If you still want to enter bytes, append a "B" - when selecting an input file with name.nnnn.ts pattern, the ".nnnn." part is now removed when forming the output filename - now asks before overwriting existin gfiles - now immediately closes the output file when processing has finished (also fixes the effect that the output file size is not shown properly until program terminates, because of not-yet written out buffers) 0.5 - fixed input file matcher to deal with filenames which include regex metacharacters (e.g. "+") 0.6 - split size can now also be specified in gigabytes (i.e. "4GB") - added experimental function to skip a certain time period at the beginning. This utilizes the PCR timestamps from transport stream adaption fields, so reliability is limited. 0.7 - also accept .tp as a file extension in UI and pattern matching - added "Multi" volume input mode, where NullPacketStripper will pop up the filerequester again after processing has finished, to select further input files to be merged into the current output. Useful for restoring from DVD media 0.8 - changed the "4300MB" default to a more accurate "4470MB" for DVD-sized splits - added ".trp" as an additional recognized extension for transport streams, and fixed handling of ".tp" in various places 0.9 - added a "Scan only"-mode, where no output files are being created, and instead a packets-by-PID statistic is dumped - added ability to customize which PIDs are to be kept or which are to be removed from streams. Default setting yields old behavior (remove 0x1fef & 0x1fff, keep all others) 0.10 - added option to "remap" PIDs in "include" mode, by specifying "currentpid=newpid" (e.g. "0x11=0x66,0x14=0x88") in the filter pattern 0.11 - due to a bug in the remapping code, NPS would always remove packets with PID 0 (the PAT), causing strange behavior during playback with some demultiplexers 0.12 - added a Quick Scan mode, similiar to Scan Only, where only 100 MB of input data will be read 0.13 - deal with segments with 1-4 digit sequence numbers