WinSubMux 0.2.0.2
by New Age
May 21st, 2002

Please _READ_ this file before sending me any questions!

WinSubMux@mailbox.hu

This program is freeware. Use at your own risk.

Source code is NOT available.


Benefits
~~~~~~~~

* it has a GUI however it can be started with command line parameters (WinXP Themes support!)

* multiplex all streams in one step

* it is fast! 
  (on a Celeron 900, 512MB ram, with very old Quantum HDDs it takes about 
   a) 3-4 minutes to multiplex a 800MB MPEG2 file if the input and output
      mpeg files are on the same HDD
   b) it is less than a minute to multiplex a 800MB MPEG2 file if the 
      input and output files are on two different HDDs)

* a lot of fixed bugs of SUBMUX, eg.:
	'underline problem': 
	        a lot of subtitles appear on screen underlined
	'disappearing subtitles': 
	        if the subtitle image was too small sometimes it doesn't appear on screen
	'corrupted audio/video frames:'
	        playing sub-multiplexed files without subs -> some frames were corrupted

* preview subtitles after load

* SVCD(MPEG2) preview on Preview Tab trough D2V (DVD2AVI Project File) file format
  [MPEG2DEC.DLL is needed!]

* easily timeshift subtitles on preview tab (align subtitle time to movie frame) 

* subtitle bitmap palette modification

* can handle large subtitle images

* save SUB file and/or bitmaps

* SVCD file-scan: get some information about your mpeg file (subs, audio, video)


Command line parameters
~~~~~~~~~~~~~~~~~~~~~~~

The program can be started from command line (batch file) with these parameters:

WinSubMux.exe [-v <level>] [-l <logfile>] <in.mpg> [ subtitle options ] <first_script.sub> <out.mpg> [ [subtitle options] [other_script.sub] ... ]

-v <level>	verbosity(debug) level (default 1)
-l <logfile>	write debug log into a file

subtitle options: MUST be BEFORE .SUB filenames!!!
-s <stream>	Substream ID of the subtitle (0..3) (default 0)
-C		make CVD subtitles (if not specified SVCD subtitles are default)

Examples:
    To insert SVCD style subtitles into Stream #2; debug level = 3
	WinSubMux.exe -v 3 INPUT.MPG -s 2 SUBTITLES.SUB OUTPUT.MPG

    To insert SVCD style subtitles into Stream #0 and CVD style subtitles into Stream #1
	WinSubMux.exe INPUT.MPG -s 0 SUB_SVCD.SUB OUTPUT.MPG -s 1 -C SUB_CVD.SUB

! Because of backward compatibility with older versions of WinSubMux and 
  with submux the first subtitle-script MUST be between the two mpeg files 
  (input, output) as it is described above !

The subtitle image format
~~~~~~~~~~~~~~~~~~~~~~~~~

It must be in "Windows Bitmap 16 color (4bit) or 256 color (8bit)" format 
and ONLY the first four color can be used as #00 for background and #01, 
#02, #03 for anything. If other colors are used the program uses the 
AND '3' operation to calculate the color index:
subtitle_color_index = bmp_color_index AND 3. 
So #04 becomes #00, #05 becomes #01, #06 becomes #02, etc.

The subtitle script file format
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The file format is similar to "PHILIPS SVCD DESIGNER 1.5 - 2.0 SUBTITLES FILE"
file format but it must contain ONLY the '[LIST]' section without the '[LIST]'
section identifier. Eg.:

ENG_000001.bmp 01:45:10:11 01:45:14:15 296 068 211 464

or

ENG_000001.bmp 01:45:10:11 01:45:14:15 296 068 211 464 0 255 255 255

where the columns are:

IMAGEFILE STARTTIME ENDTIME WIDTH HEIGHT X Y T0 T1 T2 T3 

IMAGEFILE: filename of the subtitle picture without path 
           (the pictures and the script file MUST BE in the same directory!)
STARTTIME, ENDTTIME: Hour:Minute:Second:Hundredthsecond
WIDTH, HEIGHT: width, height of the bitmap
X,Y: X,Y position (on the movie) of the lower upper corner of the subtitle image
T0, T1, T2, T3: is the contrast (or transparency) value of the #0, #1, #2, #3 colors
                0 means fully transparent
		255 means fully non transparent
***
BE CAREFUL don't make subtitles with zero or negative duration they will be skipped.
(eg: SubRip 0.97b puts '00:00:00,00' time to the last subtitle ENDTIME)


Future plans
~~~~~~~~~~~~

* bug fixing
* subtitle extraction from mpeg2 files (like vob2sub)
* non transparent subtitle backround support
* multilanguage support
* direct mpeg2 preview (open mpeg2 files not d2v files)


Known bugs
~~~~~~~~~~

* MPEG Analizing does not work correctly with MPEG1 files
* mpeg files with RIFF header (*.DAT files) works very slowly
	--> Convert to true mpeg file with 'cdxa2mpeg.exe' (part of VCDImager)


System requirements 
~~~~~~~~~~~~~~~~~~~

* IBM PC compatible computer
* Processor: at least Pentium Pro compatible
* Operating system: Windows 9x/Me/NT/2000/XP



--------------------------------------------------------------------------

MPEG2DEC.DLL is under GNU GENERAL PUBLIC LICENSE (GPL)

--------------------------------------------------------------------------
