SAMI

SAMI

Synchronized Accessible Media Interchange (SAMI) is a Microsoft accessibility initiative released in the summer of 1998.[1] The structured markup language is designed to simplify creating subtitles for media playback on a PC.

Quick Facts Filename extension, Developed by ...

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.

More information Name, Description ...

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>

<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>Le narrateur</P>
  <P Class=FRFRCC>Texte SAMI 0000</P>
</SYNC>

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

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

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

</BODY>
</SAMI>

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.

<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>

Software support

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

See also


References

  1. "Adding Closed Captioning to Your Multimedia Programs". Microsoft Developer News & Articles. Microsoft. September 1998. Archived from the original on 12 October 1999.

Further reading

  1. Gunderson, Jon (14 March 2003). "SAMI and Quicktime Captioning". The Illinois Center for Information Technology Accessibility. University of Illinois at Urbana–Champaign. Retrieved 14 June 2011.
  2. "Creating a SAMI File". Captioning for Windows Media. WebAIM. Retrieved 14 June 2011.
  3. "Software for Creating Captions". WebAIM. Retrieved 14 June 2011.

Share this article:

This article uses material from the Wikipedia article SAMI, and is written by contributors. Text is available under a CC BY-SA 4.0 International License; additional terms may apply. Images, videos and audio are available under their respective licenses.