SAMI
Synchronized Accessible Media Interchange is a Microsoft accessibility initiative released in 1998. The structured markup language is designed to simplify creating subtitles for media playback on a PC.
Overview
A SAMI file provides closed caption support for multimedia formats. Generally, a multimedia file is played by a media player such as Windows Media Player. Media players that support closed captioning and SAMI format may display the contents of the included SAMI file.A SAMI file is a plain text file and therefore can be created or modified in any text editor. Its structure is very similar to HTML. The files may have either
.smi
or .sami
filename extensions, although using .smi
may cause a filename extension collision, since Synchronized Multimedia Integration Language files and Macintosh self mounting images also use this filename extension.Supported HTML tags and CSS
SAMI format is similar to HTML and CSS; in fact, SAMI implements a subset of both. SAMI does not require strict tag matching.Name | Description |
B | Bold text style |
BASEFONT | Base font size |
BDO | I18N BiDi override |
BIG | Large text style |
BLOCKQUOTE | Long quotation |
BR | Forced line break |
CAPTION | Table caption |
CENTER | Shorthand for DIV align=center |
COL | Table column |
COLGROUP | Table column group |
DD | Definition description |
DIV | Generic language/style container |
DL | Definition list |
DT | Definition term |
FONT | Local change to font |
H1 | Heading |
H2 | Heading |
H3 | Heading |
H4 | Heading |
H5 | Heading |
H6 | Heading |
HR | Horizontal rule |
I | Italic text style |
IMG | Embedded image |
LI | List item |
OL | Ordered list |
P | Paragraph |
PRE | Preformatted text |
Q | Short inline quotation |
S | Strike-through text style |
SMALL | Small text style |
SPAN | Generic language/style container |
STRIKE | Strike-through text |
SUB | Subscript |
SUP | Superscript |
TABLE | N/A |
TBODY | Table body |
TD | Table data cell |
TFOOT | Table footer |
TH | Table header cell |
THEAD | Table header |
TR | Table row |
TT | Teletype or monospaced text style |
U | Underlined text style |
UL | Unordered list |
Example
Here's an example SAMI file. It sets the time to milliseconds. It uses CSS for formatting both the source and text lines and it supports language selection.. Each SYNC block sets the start time for the caption. A new caption is displayed every second. TheClass=
identifies the language. The ID=Source
indicates the source/speaker line; the default is the closed caption. The identifier name need not be "Source"; it may be any name.The Microsoft parser is fragile. Formatting information can be added to the closed caption information, but adding format information to the source line can have unpredictable results. Defining more than one ID can have unpredictable results.
Media
Metrics
Spec
The Speaker
SAMI 0000 text
Le narrateur
Texte SAMI 0000
SAMI 1000 text
Texte SAMI 1000
SAMI 2000 text
Texte SAMI 2000
SAMI 3000 text
Texte SAMI 3000
Association with media
The player needs to know how to associate a particular media file to a SAMI file. Sometimes that is achieved by using the same filename as the underlying media file. For example, when Windows Media Player opens the sound file cheap44.wav, it checks to see if the file cheap44.smi exists in the same folder. If it does, WMP uses that file to display closed captions.Alternatively, the association can be made explicit using an entry in an Advanced Stream Redirector file. The user opens the ASX file instead.
Software support
The following is a list of software that can play SAMI along with multimedia contents:- Chameleo
- GOM Player
- KMPlayer
- Media Player Classic Home Cinema
- MPlayer
- PBS COVE
- Perian
- PotPlayer
- Plex
- VLC Media Player
- Windows Media Player
- XBMC
- Xine