next up previous contents
Next: Soundfile Manipulation: name, clear Up: A Manual for SAWDUST Previous: Data Input/Output: save, restore,   Contents

Subsections

Creating and Playing samples: play, replay, store

play Create the samples for an object or sequence of objects, and let the user hear the sequence
store Create the samples for an object or sequence of objects, but do not let the user hear them.
replay Play the current sequence of objects

The play command

play is the command you use when you want to hear the objects you've created.

The play command does three things:         #&    # 1.&creates the samples for one or more objects; 2.&appends those samples to the output soundfile; and 3.&lets the user hear the current sequence of objects

In the example below, the play command is invoked to create a sequence of three objects: a link followed by a vary followed by another link. All three objects are assumed to have been defined.

Press RETURN to end the list of objects you want to hear.

*    play

:link1                                           # 1st object: a link

44100 samples, 1.0000 seconds, 0.0167 minutes    # link1's duration

:vary1                                           # 2nd object: a vary
..........
440958 samples, 9.9990 seconds, 0.1667 minutes   # vary1's duration

:link2                                           # 3rd object: a link
.
44100 samples, 1.0000 seconds, 0.0167 minutes    # link2's duration

:                                                # type RETURN
total:    529158 samples, 11.9990 seconds, 0.2000 minutes  # summed duration
type CR when ready:                              # type another RETURN
                                                 # Sawdust plays the
                                                 # sequence
*                                                # back to Sawdust prompt

At this point, were you to type play again and create other objects, the 2nd group would be appended to the end of the first group, and play would play back both the first and second groups, in order.

The store command

The store command allows you to append objects to the current sequence without hearing them: it's like play without its last step.

*    store                                 # invoke the command

:link1                                     # 1st object

44100 samples, 1.0000 seconds, 0.0167 minutes

:vary1                                     # 2nd object
..........
440958 samples, 9.9990 seconds, 0.1667 minutes

:link2                                     # 3rd object
.
44100 samples, 1.0000 seconds, 0.0167 minutes

:                                          # Type a RETURN
total:    529158 samples, 11.9990 seconds, 0.2000 minutes

*                                          # Back to Sawdust's prompt

As with the play command, if you were to type the store command again, and create a second group of objects, the second group would be appended to the end of the first group.

The replay command

The replay command replays the current sequence of objects.

*    replay
type CR when ready:                        # Type a RETURN
                                           # Sawdust plays the sequence
*                                          # Back to the prompt

Note for the play and store commands

Both commands append samples to current output soundfile. This means that if you have left a soundfile from a previous session with Sawdust, your current samples will be appended to it, and when you play the samples, you will hear both the samples left from the previous session, as well as those from the current session.

Use the name or clear commands to delete or rename the output soundfile.

Generating silence with the play and store commands

Both play and store will generate silence, if you input a duration rather than the name of an object.

The duration is given in samples, so if you wanted a silence of 2 seconds, you would type in the number 88200, since Sawdust's sampling rate is 44100 samples per second.


next up previous contents
Next: Soundfile Manipulation: name, clear Up: A Manual for SAWDUST Previous: Data Input/Output: save, restore,   Contents
Arun Chandra 2001-05-18