How to Fade-In/Fade-Out a Sampled/Repeating/Mixed Sound--another Elephant through a keyhole!

Rob Rothwell r.j.rothwell at
Thu May 4 15:46:30 UTC 2006


Wow.  This is unknown territory to me.  Can you point me towards some kind
of example of initializing an FMSound in this way to start trying to figure
out what you meant by all of that?  Once I have a place to start I can
usually get somewhere (although my debugging skills are still sort of
limited to adding a bunch of "Transcript show: ..." code to a method).

I still consider myself new to Squeak and have realized that it is not the
language that is difficult, but the complexity of the problems (and
therefore solutions) that are "documented" in the code that everyone advises
you to read to learn from.  It's not that it's hard to find some code that
does something, it's hard understanding what it does!  For me, it's an
endless loop of struggling to figure out how to do something because I can't
understand how something I DO know how to use does what it does, etc,
etc...  I think this is what many people are referring to with the many
posts about the "Elephant through the keyhole."  From my point of view,
Squeak is being used by very smart people solving difficult, specialized
problems--not by ordinary programmers using Squeak to do things that many
other people do as well.

Thus, because Squeak is not "mainstream", it's not like you can just find a
code snippet that does what you want with a few Internet searches to begin
your exploration like you can with the endless varieties of VB or .NET, but
I find myself increasingly drawn to Squeak nonetheless because it feels like
anything is possible with an EQUAL amount of elegance.  The same things are
possible in other languages, too (if the computer can do it!), but the
solutions often feel like a hack.  I use a lot of VBA at work, and sure, you
can do it, but...yuck.  Everything that you WANT to do is ALWAYS a
work-around of some kind.

I spent many years trying to write my own language/OS in assembly language
before I even knew that Smalltalk had been invented.  That's what I got for
studying Physics instead of Computer Science, I guess!  Well, Squeak is very
nearly what I had in mind all those years, so I think my new goal is to
learn how to use it and find a way to make it practically useful to the
mainstream, because it has all the potential, it just needs a bridge to the
everyday programmer, if not to the everyday user (those are probably two
separate issues).

Anyway, thanks for your help.  I hope one of the sound jocks is out there
too!  Sorry for rambling, but there seems to be a lot of that going around


>Doggone.  I see now that you had this figured out and were having problem
with sampled >sounds.
>The one thought I have without getting into it deeply is that you might be
able to initialize an >FMSound in such a way that its buffer comes from  '
aWAVFile.wav, and its various >parameters cause it simply to be played
through once with no FM (ie the degenerate case >is basically like a
SampledSound.  Then I think the envelope logic should work.
>Hopefully you'll hear more from one of the real sound jocks.
>       - Dan
-------------- next part --------------
An HTML attachment was scrubbed...

More information about the Squeak-dev mailing list