Availability: IRIX.
This module provides an interface to the Silicon Graphics CD library. It is available only on Silicon Graphics systems.
The way the library works is as follows. A program opens the CD-ROM device with open() and creates a parser to parse the data from the CD with createparser(). The object returned by open() can be used to read data from the CD, but also to get status information for the CD-ROM device, and to get information about the CD, such as the table of contents. Data from the CD is passed to the parser, which parses the frames, and calls any callback functions that have previously been added.
An audio CD is divided into tracks or programs (the terms are used interchangeably). Tracks can be subdivided into indices. An audio CD contains a table of contents which gives the starts of the tracks on the CD. Index 0 is usually the pause before the start of a track. The start of the track as given by the table of contents is normally the start of index 1.
Positions on a CD can be represented in two ways. Either a frame number or a tuple of three values, minutes, seconds and frames. Most functions use the latter representation. Positions can be both relative to the beginning of the CD, and to the beginning of the track.
Module cd defines the following functions and constants:
) |
minutes, seconds, frames) |
(minutes, seconds, frames)
triple
representing time in absolute time code into the corresponding CD
frame number.
[device[, mode]]) |
'/dev/scsi/sc0d4l0'
, or
None
. If omitted or None
, the hardware inventory is
consulted to locate a CD-ROM drive. The mode, if not omited,
should be the string 'r'
.
The module defines the following variables:
audio
.
The following variables are states as returned by getstatus():
See About this document... for information on suggesting changes.