[comp.sys.mac.misc] Fix for bad sounds in 6.0.7

rrr@u02.svl.cdc.com (Rich Ragan) (11/06/90)

Recently, I reported that some of my sounds crashed system 6.0.7
or simply did not play (the sounds of silence :-). Attached is
a description of the cure (it worked for me).
------
From:    Steve Brecher

On my IIfx with System 6.0.7, some of my sounds -- all of which played
under 6.0.5 -- no longer play, and some do play OK.  I tried moving
one of the sounds that no longer plays into the System, restarting
without Suitcase II, and the sound still did not play.  I used both
the Sounds control panel and ResEdit in trying to play the sound.

My conclusion from my experience is that the problem is not related to
Suitcase II, nor to whether the sounds are "suitcased."  The problem
seems to affect some specific sounds and not others.  It doesn't
appear to be related to the size of the 'snd ' resource, as the one I
moved into the System and which still didn't play is quite small.

I went on to see if I could determine why the problem sounds don't
play at all on my system.  All of the sounds that I looked at are
sampled (recorded) sounds with a similar structure -- technically, one
synthesizer, the sampled sound synthesizer, and one command,
bufferCmd.  I found that the problem sounds had a different format
than the ones that worked; when I changed the format of the problem
sounds with ResEdit, they worked (played).  I concluded that the new
6.0.7 Sound Manager is more sensitive to the "defective" format, in
other words, the earlier Sound Manager was more lenient.  Technically,
the problem sounds had only two bytes of zeros for the fields which
specify the start and end of the alternate sampling loop, while the
good sounds had eight bytes -- the latter is the proper combined size
of these two fields per the Sound Manager technical documentation.

If you wish to try what I did, in ResEdit open a snd resource for a
sound that doesn't play.  (Make sure it's a *copy* of your sound
suitcase that you're working on, in case things go wrong.) The
contents of the snd resource will be shown in hex.  If it is one that
is amenable to this experiment, the beginning of it will look like
this:

 000000    0001 0001 0005 0000
 000008    0000 0001 8051 0000
 000010    xxxx 0014 0000 0000
 000018    0000 xxxx xxxx xxxx
 000020    0000 xxxx xxxx xxxx
          ^

The first column is ResEdit's display of the starting position
relative to the start of the resource, in hexadecimal, of the bytes
shown in the remaining columns. xxxx denotes a value which may vary
between different sounds.  (For "good" sounds, the last three xxxx are
zeros.)  To alter the resource, click just at the left of the second
column in the fifth line (as indicated by the "^" above) to make an
editing insertion point, and insert six bytes of zeros.  Each byte is
two characters, so strike the "0" key twelve times.  Then close the
window.

If you have a late-model ResEdit, it will have a "snd" menu that will
let you try the sound both before and after the edit, and you can tell
immediately whether the change makes a difference.

Note that if the suitcase was packed by Font & Sound Valet, editing
and saving a snd resource will unpack that sound on disk.
---------------------------

--
Richard R. Ragan  rrr@svl.cdc.com  (408) 496-4340 
Control Data Corporation--Silicon Valley Operations