Share on Facebook Share on Twitter Email
Answers.com

SAMI

 
Wikipedia: SAMI

SAMI (Synchronized Accessible Media Interchange) is a Microsoft accessibility initiative released in 1998. The structured markup language is designed to simplify creating captions for media playback on a PC, i.e. not for broadcast purposes.

SAMI documents are text, and can be written in any text editor, although there are special utilities available to create SAMI documents. They use .smi or .sami file extensions. The common use of .smi for SAMI files creates a file extension collision with SMIL files.

Each SAMI document may contain more than one language.

SAMI is the predominant caption file format in South Korea.

Contents

Provides Closed Caption Information

A SAMI file provides closed caption support for a variety of multimedia formats. Generally, a multimedia file (such as a video or a sound file) can be played using a utility such as Windows Media Player. Closed captions can be provided for that media via a separate SAMI file.

How SAMI Works

The multimedia file and the SAMI file are synchronized by timing information that is included in the SAMI file. The format is simple. The SAMI file basically tells the player to display a certain closed caption at a particular time.

Basic Example

Here's an example SAMI file. It sets the time to milliseconds. It uses CSS for formatting for 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 (start=). 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>

<HEAD>
<TITLE>SAMI Example</TITLE>

<SAMIParam>
  Media {cheap44.wav}
  Metrics {time:ms;}
  Spec {MSFT:1.0;}
</SAMIParam>

<STYLE TYPE="text/css">
<!--
  P { font-family: Arial; font-weight: normal; color: white; background-color: black; text-align: center; }

  #Source {color: red; background-color: blue; font-family: Courier; font-size: 12pt; font-weight: normal; text-align: left; }

  .ENUSCC { name: English; lang: en-US ; SAMIType: CC ; }
  .FRFRCC { name: French;  lang: fr-FR ; SAMIType: CC ; }
-->
</STYLE>

</HEAD>

<BODY>

<-- Open play menu, choose Captions and Subtiles, On if available -->
<-- Open tools menu, Security, Show local captions when present -->

<SYNC Start=0>
  <P Class=ENUSCC ID=Source>The Speaker</P>
  <P Class=ENUSCC>SAMI 0000 text</P>

  <P Class=FRFRCC ID=Source>French The Speaker</P>
  <P Class=FRFRCC>French SAMI 0000 text</P>
</SYNC>

<SYNC Start=1000>
  <P Class=ENUSCC>SAMI 1000 text</P>
  <P Class=FRFRCC>French SAMI 1000 text</P>
</SYNC>

<SYNC Start=2000>
  <P Class=ENUSCC>SAMI 2000 text</P>
  <P Class=FRFRCC>French SAMI 2000 text</P>
</SYNC>

<SYNC Start=3000>
  <P Class=ENUSCC>SAMI 3000 text</P>
  <P Class=FRFRCC>French SAMI 3000 text</P>
</SYNC>

</BODY>
</SAMI>

How SAMI links to a Multimedia File

The player needs to know how to link a particular media file to a SAMI file. Sometimes that is achieved by using the same filename as the underlying media file but using a .SMI file extension. 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 directory. If it does, WMP uses that file to display closed captions.

Alternatively, the linkage can be made explicit using an entry in an ASX file and opening the ASX file.

<asx version="3.0" previewmode="No" >
  <abstract>ASXHEAD This is the shows abstract</abstract>
  <title>ASXHEAD The show title goes here</title>
  <author>Author Name</author>
  <copyright>(c) 2002 - company name</copyright>

  <entry>
    <ref href="cheap44.wav?sami=cheap44.smi" />
    <abstract>ASX This is the clips abstract</abstract>
    <title>ASX The title for the clip goes here</title>
    <author>ASX Your Name</author>
    <copyright>ASX (c) 2000 - company name</copyright>
  </entry>

</asx> 

Use of HTML Tags and CSS

SAMI format is similar to and borrowed from HTML and CSS, but SAMI only implements a subset of both. SAMI does not require strict tag matching.

The Microsoft SAMI parser used in Windows XP is a limited parser. Although CSS is supported, the parser may be confused by comment lines. Although several examples on the web show the use of several CSS ID tags, the MS SAMI parser only uses two ID tags -- and perhaps only one named ID and one default ID. The ID tags are used to distinguish the source (speaker) line from the ordinary CC text. Using explicit format tags in the speaker line confuses the parser. Some automated tools may avoid the problem by using explicit text formatting rather than relying on CSS.

The following HTML tags are valid in SAMI:

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

Media Players that Support SAMI

SAMI Authoring Tools

See also

External links


Search unanswered questions...
Enter a question here...
Search: All sources Community Q&A Reference topics
 
 
Learn More
Sami (member of a people of nomadic herding tradition)
Shamon (family name)
tundra (word origin: Russia)

What do reindeers at in the Sami? Read answer...
Who is sami h? Read answer...
What rhymes with Samie? Read answer...

Help us answer these
Who is Samy Bensidhoum?
The sami europe?
What is samis?

Post a question - any question - to the WikiAnswers community:

 

Copyrights:

Wikipedia. This article is licensed under the Creative Commons Attribution/Share-Alike License. It uses material from the Wikipedia article "SAMI" Read more

 

Mentioned in

  • Sami (member of a people of nomadic herding tradition)
  • Shamon (family name)
  • tundra (word origin: Russia)
  • Lapp