2. DVD Subtitle Encoder

DVD subtitle encoder creates sup-files suitable for IfoEdit authoring.

Usage: DVDSupEncode.exe [-options] subtitle1.txt [subtitle2.txt ...]

where subtitle1.txt is source subtitle text

options

-help display help

-nolog suppress log-file generation

-force force encoding regardless errors

-p:profile load setting from profile (profile = section in DVDSupEncode.ini)

-version display version info

Source text file contains subtitles in format

{frame_from}{frame_to}line

{frame_from}{frame_to}line_1|line_2

or comments in format

;this is comment line, will be ignored

External bitmaps can be also loaded from given location

{frame_from}{frame_to}{d:\my_pictures\file_name_1.bmp}

Source text file can also contain processing commands:

FrameW=n frame width (720, 704)

FrameH=n frame height (576, 480)

FrameRate=n frame rate (25, 29.97)

Delay=n subtitle delay (in frames)

(previous commands can be specified only at the beginning of source text)

FontName=name subtitle font name

FontCharSet=n subtitle character set (for more detail information see Font Setting)

FontSize=n subtitle font size

FontStyle=n subtitle font style (REGULAR, BOLD, ITALIC, UNDERLINE)

Contour=n creates black contour around subtitle characters (n pixels wide)

Palette=n color palette used

Alpha=n alpha channel setting

OnTop=0|1 subtitles are created on the top of the screen

Justify=C|L n|R n subtitles are justified to the center/left/right (n pixels from the frame border)

Indent=n subtitles are indented n lines from the bottom/top of the frame (should be even number)

DynamicSize=0|1 subtitle frames have dynamic bitmap size

RightToLeft=0|1 text is read right to left (Hebrew, Arabic)

ShowBitmap=0|1 creates bitmap files during processing

Every command is valid until it is set to new value. Default values are taken from C:\Documents and Settings\<user>\DVDSupEncode.ini,

section [Default], and are predefined as follows:

FrameW=720

FrameH=576

FrameRate=25

Delay=0

FontName=Arial

FontCharSet=238

FontSize=23

FontStyle=REGULAR

Contour=1

Palette=3210

Alpha=FFF0

OnTop=0

Justify=C

Indent=40

DynamicSize=0

RightToLeft=0

ShowBitmap=0

Additional sections [profile] can be specified in DVDSupEncode.ini. These profiles allow you to switch quickly your favorite predefined settings. Profiles can be activated by command line parameter -p:profile. Structure of these profiles (i.e. entries) is the same as for [Default].

The priority of activation of settings is as follows: 1. setting in source-text

2. setting in selected profile

3. setting in Default profile

4. program internal setting

During process of creation of subtitle sup-file is generated log-file. Into log-file are reported warnings and errors in case that created subtitle doesn't fit into the screen.

Loading external bitmaps is also supported. Size of these bitmaps should be the same as size of the frame, color-depth will be reduced to 4 according to luminance, i.e. interval <0,255> is uniformly divided into 4 ranges and every range is associated with one entry in subtitle palette.

IMPORTANT: After authoring in IfoEdit don't forget to set up Subtitle Color properly!

For PALETTE=3210 can be used following colors:

VTS_01_0.IFO

VTS_PGCITI

VTS_PGC_1

[000000a5] Color 0 Y Cr CB 16 128 128 [10 80 80 ]

[000000a9] Color 1 Y Cr CB 32 128 128 [20 80 80 ]

[000000ad] Color 2 Y Cr CB 128 128 128 [80 80 80 ]

[000000b1] Color 3 Y Cr CB 235 128 128 [eb 80 80 ]

It is highly recommended firstly to check subtitles on DVD rewritable disk (and thus prevent from damaging of recordable media).