SAMI

{{More citations needed|date=July 2022}}{{Other uses|Sami (disambiguation)}}

{{Infobox file format

| name = Synchronized Accessible Media Interchange

| icon =

| logo =

| screenshot =

| caption =

| extension = .smi, .sami

| mime =

| type code =

| uniform type =

| magic =

| owner = Microsoft

| type = Timed text

| container for =

| contained by =

| extended from = HTML

| extended to =

| standard =

| url =

| open = Yes

| free = Proprietary

| released = {{start date and age|1998|06|25|df=y}}

}}

Synchronized Accessible Media Interchange (SAMI) is a Microsoft accessibility initiative released in the summer of 1998.{{cite news |title=Adding Closed Captioning to Your Multimedia Programs |url=http://www.microsoft.com/enable/dev/msdn8.htm |work=Microsoft Developer News & Articles |publisher=Microsoft |date=September 1998 |archive-url=https://web.archive.org/web/19991012040710/http://www.microsoft.com:80/enable/dev/msdn8.htm |archive-date=12 October 1999}} 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 (such as a video or a sound 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 (SMIL) 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.

class="wikitable sortable"

|+Valid HTML tags in SAMI{{cite web|url=http://msdn.microsoft.com/en-us/library/ms971327.aspx|title=Understanding SAMI 1.0|date=February 2003|work=Microsoft Developer Network|publisher=Microsoft Corporation|accessdate=14 June 2011}}

! Name

! Description

BBold text style
BASEFONTBase font size
BDOI18N BiDi override
BIGLarge text style
BLOCKQUOTELong quotation
BRForced line break
CAPTIONTable caption
CENTERShorthand for DIV align=center
COLTable column
COLGROUPTable column group
DDDefinition description
DIVGeneric language/style container
DLDefinition list
DTDefinition term
FONTLocal change to font
H1Heading
H2Heading
H3Heading
H4Heading
H5Heading
H6Heading
HRHorizontal rule
IItalic text style
IMGEmbedded image
LIList item
OLOrdered list
PParagraph
PREPreformatted text
QShort inline quotation
SStrike-through text style
SMALLSmall text style
SPANGeneric language/style container
STRIKEStrike-through text
SUBSubscript
SUPSuperscript
TABLEN/A
TBODYTable body
TDTable data cell
TFOOTTable footer
THTable header cell
THEADTable header
TRTable row
TTTeletype or monospaced text style
UUnderlined text style
ULUnordered 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. (English and faux-French shown). Each SYNC block sets the start time for the caption. A new caption is displayed every second (1000ms). The Class= identifies the language. The ID=Source (matching the #Source in the CSS identifier definition) 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.

SAMI Example

Media {cheap44.wav}

Metrics {time:ms;}

Spec {MSFT:1.0;}

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 (WMP) 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 (ASX) file. The user opens the ASX file instead.

ASXHEAD This is the shows abstract

ASXHEAD The show title goes here

Author Name

(c) 2002 - company name

ASX This is the clips abstract

ASX The title for the clip goes here

ASX Your Name

ASX (c) 2000 - company name

Software support

The following is a list of software that can play SAMI along with multimedia content:

See also

References

{{reflist}}

Further reading

{{Refbegin}}

  1. {{cite web|last=Gunderson|first=Jon|title=SAMI and Quicktime Captioning|url=http://cita.disability.uiuc.edu/presentations/2003-03-14-HCC/part2/index.html|work=The Illinois Center for Information Technology Accessibility|publisher=University of Illinois at Urbana–Champaign|accessdate=14 June 2011|date=14 March 2003}}
  2. {{cite web|title=Creating a SAMI File|url=http://webaim.org/techniques/captions/windows/sami|work=Captioning for Windows Media|publisher=WebAIM|accessdate=14 June 2011}}
  3. {{cite web|title=Software for Creating Captions|url=http://webaim.org/techniques/captions/software|publisher=WebAIM|accessdate=14 June 2011}}

{{Refend}}

Category:Microsoft Windows multimedia technology

Category:Subtitle file formats

Category:Playlist file formats

Category:Film and video technology

Category:Playlist markup languages

Category:1998 introductions