Class: Sound

Environment: Siren
Superclass: Siren.Function
Category: Music-Sound
Indexed variables: objects
Imports: private SoundConstants.*

Instances of the subclasses of Sound are used to represent sound objects.
The abstract class Sound is vacuous.
Sounds use their Function and DurationEvent behaviors actively.

testing

isSound
Answer true.

initialize-release

finalize
Free the receiver's external data, if any

initialize
Set up a default sound.

cue accessing

addCueNamed: cName from: start to: stop
Add the given named cue region to the receiver's list.

cueList
Answer the receiver's 'cueList'.

cueList: CollectionOfCues
Set the receiver's 'cueList' to be the given OrderedCollection of (#name -> (start to: stop)) cues.

cueNamed: cName
Answer a sound derived from the receiver using the samples between the named cue points.

cueRegionNamed: cName
Answer a indices for the samples between the named cue points.

MetaClass: Sound class

instance accessing

named: aName
Answer the sound by the given name, or nil.

named: aName put: aSound
Put the given sound in the shared dictionary under the given name.

utilities

fromFile: nameString
Open the given file (AIFF, IRCAM, NeXT, or SPARC soundfile format)

playFile: theName
Play the sound file with the given name