^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
DEVELOPERS' WORKSHOP:
Whistle While you Work
By Doug Fulton -- <lbj@be.com>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

I haven't got much time.  My fans -- and there are many of
me -- will be annoyed that this article isn't very amusing,
but I have this feeling of impending, if cartoonish, dread.
I can see the shadow of a sandstone boulder spreading
concentrically about me as if I sat permanently in some high
noon Arizona on the Equator. It's a race between that and
the floor dropping out in a neat circle around me, as the
sawcut from the apartment below is nearly complete.
Granting, of course, that the steam roller (slow, but I'm
glued to my chair, and my chair is nailed to the floor)
doesn't get here first.

Or maybe it's this here new application, 'Whistle'.  Whistle
turns every day into a Warner Brothers cartoon.  Type and
everything in your cupboard falls on the floor. Move the
mouse and you're running up and down stairs (in stereo!).
Click the mouse and the creature walks.  Plus it has an
interface that's more fun than dropping bowling balls on a
duck's head (featuring the new PigTail control -- move it
and it dances).

The literature says "Whistle makes noise in response to user
events." Does it ever. To procure the source code to said
program, click on this URL:

<ftp://ftp.be.com/pub/samples/midi_kit/Whistle.zip>

Next, make sure you have the Beatnik software synthesizer
loaded on your machine: Do a find on "big_synth.sy".  If
it's missing, get out your Release 4.5 CD and reload the
thing (it's in there somewhere).

That done, launch the app.  The interface shows up
immediately; the music won't start for a few seconds (the
synthesizer takes awhile to load).  The three sliders in the
Whistle window (and, yes, they *are* supposed to look like
that) set the volume for keyboard ("K"), mouse moved ("M"),
and mouse button ("B") events. Type tab or the arrow keys to
tweak the sliders from the keyboard.

A word of caution:  Whistle's interface uses app server
features that are largely untested, and uses them a lot.
The interface *does* leak memory, but we're not sure where
the leak is yet.  If you see your swap space disappearing
(for a quick swap space monitor: Control+Alt+"About BeOS" in
the Be Menu), but you still want to run the app, use the
command line version:

$ Whistle -q -k keyboard_vol -m mouse_vol -b buttons_vol

The -q switch suppresses the interface.  The other switches
set the volume levels for the three event streams; volumes
are in the [0.0, 1.0] range.

That's all folks.
