Plotting Real Time Audio
The applet below combines Gabriele Bulfon's
Playing Wave applet and the
Ptplot class. The
sources show how we added a PlotLive widget. This demo is not very
polished, we did it so that we could experiment with multithreaded applets.
This demo simulates a plucked string sound using the
Karplus-Strong algorithm. The user can control the various features
of the new sound, and then mouse on the action button, which will create the
The user controlled features are:
Note that the wave plot on the left side is mouse sensitive. If you
depress and hold the left mouse button while over the signal, you
can drag the signal around.
- This widget determines whether the new sound replaces the
old sound or adds to the old sound.
- This widget determines whether the new sound will be a random
wave, or a sine wave.
- Text entry widget
- This widget is used to set the period of the sine wave.
- This button causes the new sound to be generated
Damp slider and entry widget
- This controls the damping. If the value is more than
then the sound gets louder, if the value is less than
For more information about this applet, see the
Playing Wave webpage
Up to the Example index -
Back to a Plot of 10,000 binary points
Copyright © 1997, The Regents of the University of California.
All rights reserved.
Last updated: 10/31/97
comments to: firstname.lastname@example.org