From: dcole@ua.d.umn.edu (david cole)
Newsgroups: comp.sys.ibm.pc.soundcard
Subject: Re: On GUS memory (question)
Date: 1 Jan 1993 19:32:10 -0600
Organization: University of Minnesota, Duluth
NNTP-Posting-Host: ua.d.umn.edu

In article <1993Jan1.215241.16188@netcom.com> stewarta@netcom.com (Alex Stewart) writes:
>
>So, let's just sample 1/440th of a second of it (one cycle), and then make a
>note that the entire thing consists of that sample 440 times.  We have to deal
>with attack and decay, but we can do that by just putting in a little data 
>that says "start the amplitude at 0, raise it at such-and-such a rate until we
>get to full volume, wait for the release, then decay similarly".  This 
>information need only take up a few bytes.  We now have exactly the same result
>at exactly the same sampling rate/clarity, etc.  It now takes up somewhere 
>slightly over 100 bytes.
>
   [stuff deleted]	
>A more complex instrument may need a different sample for the attack phase or 
>the decay phase, but this can be whittled down similarly to only the necessary
>information.  When you get finished, a 16-bit 44Ks/s piano can be stored in 
>somewhere around 20-30K (just guessing), add to that any compression, and you
>have no problem fitting several high-quality instruments in 1Meg, or even 256K,
>and you get better quality than straight samples, to boot.
>
>Hope this helps (hope I'm not way off base, too...),
>-alex
>

Unfortunately, this method works for a bass, but you are off-bass when it
comes to pianos  :)  Note that if it were true, you wouldn't have current
synthesizers with 4-8 megs of standard sample rom just to get mostly acoustic
instruments.  And a good piano takes 1 meg or more of sample.

The reason is that the piano and many other instruments have a very complex
sound that varies in harmonic content both with time and with pitch.  For
example, a piano has single very thick (wrapped) strings for low notes, and
two strings for middle notes, and three strings for each high note.  Much of
the tone is contributed by the case (especially the back (in an upright) or
bottom in a grand).  You cannot get a decent piano sound by sampling a single
cycle and then including some instructions on how to repeat and decay it.
The attacks are extremely complex, since the hammer contact divides the
string into two sections with their own harmonic characteristics.  And you
cannot simply shift the frequency up and down and get a good sound.  If the
note was sampled at middle C it will start to sound wrong as soon as you get
an octave away. The best dedicated digital pianos sample EVERY note and have
a complete sample from attack to final decay -- no looping.  Most
synthesizers do not sample every note, but do have 6-8 samples of the pianos
range, and do not try to frequency shift more than an octave, less in the
prime middle range.  It is very difficult to make looping that is not quite
audible (because the harmonic content is changing as the note decays, so you
hear it loop back to a point with different harmonic content). 

So in practice, with complex acoustic instruments such as the piano, synth
makers have found they must use large samples.  This is why I am skeptical
about the GUS -- it only has 1 meg MAX sample space.  How can you possibly
play a decent piano and any other instrument at the same time?  Do you buy a
GUS for each instrument?  I don't see what the point of crippling the sample
space is, or of using 256k chips.  We will see what Ensoniq puts on their
card....  If they use 256k chips for RAM instead of 1 or 4 Meg simms, I will
be very surprised (and disappointed).  The idea of using RAM is a good one,
but it should be done with a reasonable use of current technology (most
consumer outlets don't even carry 256k chips anymore, they are virtually
obsolete).  

But I digress.  Making synthetic anything is similar. It is fairly easy to
get something that approximates the thing your are trying to simulate.  But
getting it more realistic gets harder and harder the closer you try to get.
There is merit to your original proposal, but to do it right you have to have
a model of all the components of, say, a piano, and how they intereact over
time to affect the sound.  I turns out to be easier just to record the damn
thing and play it back.  But that takes lots of memory.  

Cheers,

Dave Cole





-----------------------------------------------------------------------------
>Alex Stewart:         Sysop of YBBS (510) 689-8952 |   This space for rent.
>stewarta@netcom.com   .----------------------------'-------------------------
>stewarta@carleton.edu | Somebody, somewhere, is offended by what I am saying.
>-----------------------------------------------------------------------------


Newsgroups: comp.sys.ibm.pc.soundcard