Subject: Re: Apple IIGS sounds -> Macintosh From: supertimer@aol.com (Supertimer) Date: Thu, Jun 18, 1998 347¥ EDT Message-id: <1998061807474900.DAA09491@ladder03.news.aol.com> spec@vax2.concordia.ca (Mitchell Spector) wrote: >In article supertimer@aol.com (Supertimer) writes... > >>Gabriel Morales wrote: >> >>>Supertimer wrote: >>>> >>>> I have always found it ironic that Wintel and Macintosh have such >>>> a hard time with "raw" sound files. Unless the sound files are in >>>> certain well defined formats (.wav, .au, etc.) they choke on them. >>>> >>>> It is never this way with the IIGS or the Amiga. I've sent Amiga >>>> owners raw sound files from the GS...no problem. I have yet >>>> to get a Wintel or Mac to read a raw sound file from a GS. >>> >>>Why do you keep comparing the MAc to a PC! They're not the same thing! >> >>I'm not saying they ARE the same thing, just that they are both amazingly >>finicky as far as sound files go. If you know of a Mac program that can >>handle raw sound files from a GS or Amiga, I'd like to know. ;-) >> >>Same goes for Wintel. > > It is quite simple, I do it all the time. One example is CoolEdit >Pro for Windows 95, it loads in raw digitized waveforms from the IIgs >and then you manually set the playback sample rate. There are several >programs which do the same from DOS, which I also occasionally use. >CoolEdit Pro is shareware in case your wondering. Mitchell, how about emailing me this shareware? Thank you! > I'm not sure about the Macintosh since I don't own one. Another >neat thing if you have a PC, you can directly play Soundsmith music >(without any IIgs emulator involved) using Ian Schmidt's MTP, and it >actually sounds crisper than a real GS because there is no low pass >filter. :) I'm interested in a Macintosh program that does the same too. If a Mac user knows of one, email that to me too. Thanks! The low pass filter enhances the sound, not degrades it. Henrik Gudat admitted as much after I emailed him the following. ;-) >>> Subject: Re: Q: Applied Engineering Sound Card From: mjmahon@aol.com (MJMahon) Date: 1997/03/29 Message-ID: <19970329074700.CAA26305@ladder01.news.aol.com> Newsgroups: comp.sys.apple2 [More Headers] [Subscribe to comp.sys.apple2] Mitchell Spector (spec@vax2.concordia.ca) wrote: >>>The final blow to the chip was the low-pass cut-off filter that the >>>GS added. Apparently, from what I'm just finding out now, regardless >>>of whether the chip or software played a sample at 44.1 kHz (or other >>>high frequencies) the filter would essentially drop the quality down >>>to around 26 kHz. >> >>Mitchell, could you post the passage from this article? From what >>I've read, the GS does not have such a filter, but the Amiga >>does. The author of the article that I read said that the Amiga's >>sound can sometimes be cleaner because it has a low-pass cut-off >>filter that filters out the ultrasonic frequencies. He said that >>the GS lacked such a feature. > > The Ensoniq has no low-pass filter, but there _is_ one on the IIgs >motherboard (everything coming out of the chip has to go through it). >This lowers the quality of the Ensoniq when your playing higher >frequency sound (roughly anything above 26 kHz). I have heard that >the Amiga 1000 had a low-pass filter as well, but you could modify >the board to by-pass it (I think the Amiga 500/2000 also had one, >but you could disable it through software?). > > Article? Well I do have an e-mail message from David Empson who >was explaining the technical details behind the low-pass filter, but >I don't want to post it without his permission. It certainly does >exist though, I've found references to the low-pass filter in some >Addison Wesley books and it should be covered in the Apple II technotes. >It definitely is not an advantage to have one. :/ Wrong. Sampling theory is quite clear on this point. When any signal is recreated from discrete samples, there is no useful output above one-half the sampling frequency, the so-called Nyquist frequency. If energy above the Nyquist frequency is not filtered out, it will only increase the noise in the re-created waveform. Think of it this way: the unfiltered output is a stairstep approximation to the sound being produced, while the desired sound is a continuous waveform (with maximum frequency not exceeding Sampling Freq./2). The same filtering must be applied prior to sampling an input waveform, since any energy above the Nyquist frequency would simply be "folded back" (aliased) into the frequency range from 0 to Nyquist freq. Since "brick wall" lowpass filters are hard to make and have undesirable phase-shift characteristics near the cutoff frequency, gentler lowpass filters are used, which will be 3db down somewhat before the Nyquist frequency, so that they can be >30db down at the Nyquist frequency (and beyond). Note that much lower lowpass cutoffs should be used when sampling at lower frequencies. For example, if sampling at 11KHz, then the lowpass should cutoff lower than 5.5KHz, the Nyquist frequency. There ain't no such thing as a free lunch--and you can't do better than the Nyquist frequency! A lowpass simply acknowledges reality and makes for a proper design. -michael Email: mjmahon@aol.com Home page: http://members.aol.com/MJMahon/ Subject: Why we have low pass filters, the Nyquist theorem (was Re: Expand ing Focus Capacity) From: pubpc1@library.ucla.edu Date: 1998/03/06 Message-ID: <35002850.4B6A@library.ucla.edu> Newsgroups: comp.sys.apple2 [More Headers] [Subscribe to comp.sys.apple2] Mitchell Spector wrote, in response to my reply: >>You must have not been paying attention, I'm saying it does >>not matter. According to theory, you can capture a maximum >>frequency of 1/2 the sampling rate. That means that even >>though a CD player is sampling at 44kHz, the maximum signal >>frequency it can carry is 22kHz. What's above 22kHz is >>NOISE. That 26kHz low pass filter is only filtering out >>NOISE. You have to playback at 52kHz (double the 26kHz low >>pass filter) for the filter to have the effect you are >>thinking about. > > So now there is no such thing is WYSIWYG, and there is >no difference between 22 kHz and 44 kHz. Uhuh. The way I >see things, your trying to make excuses about the graphic >and sound limitations of the GS so you can still compare >it favoribly to modern computers. Mitchell, you have not been paying attention. I am just about to pull a Nathan Mates here! Have you ever heard of the Nyquist theorem? You haven't, have you? Point your web browser to: http://www.opus1.com/~violist/help/nyquist.html and read that carefully. Digest the information, now. Do you see the explanation about the low pass filter. Once again, here are the highlights of the Nyquist theorem and why we have low pass filters: The Nyquist Theorem: ---------------------------------------------------------------- What about the high end? The sampling frequency determines the limit of audio frequencies that can be reproduced digitally. One of the most important rules of sampling is called the Nyquist Theorem, which states that the highest frequency which can be accurately represented is one-half of the sampling rate. So, if we want a full 20 kHz audio bandwidth, we must sample at least twice that fast, i.e. over 40 kHz. If we don't, bad things happen. Here's our example sine wave again: (see web page for graphic) ---------------------------------------------------------------- Why we have low pass filters: ---------------------------------------------------------------- (graphic of a mangled sine wave) Because of this, A/D converters must use lowpass filtering to remove all signals above the Nyquist frequency. Of course, it also means that in order to get high-fidelity sound, we have to take a lot of snapshots. ---------------------------------------------------------------- Quick, Mitchell, what is the proper design of an A/D converter? Answer: "a low pass filter must be used to remove all signals above the Nyquist frequency." When a CD player samples at 44kHz, the objective is to capture 22kHz frequencies. What is above 22kHz is NOISE. CD players also have low pass filters that chop off the NOISE above the Nyquist frequency. I _strongly_ suspect that if the designers of PC sound cards have any brains at all, most PC sound cards would also have low pass filtering. Sure, it may be more advanced than that of the GS (I can imagine that their low pass filtering would sweep at 6kHz for 11kHz samples and 24kHz for 44kHz samples), but it is PROPER DESIGN to have one. Otherwise, you get NOISE. >>First, sample a sound on your PC at 44kHz and 16 bit. >>Then sample the same sound at 44kHz and 8 bit. Can you >>hear a difference? Probably, but it is subtle. Take >>the 44kHz 8 bit sound to the GS and play it. There is >>absolutely no difference in quality between this playback >>and the playback of the PC (the 44kHz 8 bit one, that is). > > So essential your trying to tell me sound or music recorded >at 16-bit, 44 kHz--and the same sound recorded at 8-bit, 22 kHz, >will sound more or less identical in quality? No. I am saying there is a subtle difference between 16-bit, 44kHz sound and 8-bit _44kHz_ sound. Those kHz are the SAMPLING RATE! Maximum frequency captured is _1/2_ the sampling rate. When your PC sound cards are sampling at 44kHz, only 22kHz of that is the maximum frequency capture. What is above that is NOISE. Most likely, your Roland is doing the right thing and taking out the noise above the NYQUIST FREQUENCY of 22kHz (or a little above that) with A LOW PASS FILTER. When you take the 8-bit 44kHz SAMPLE to the GS, the Ensoniq plays it as an 8-bit 44kHz SAMPLE. Maximum frequency captured is _1/2_ the sampling rate. What is above that is NOISE. The sound gets CLEANED UP through the low pass filter. You lose nothing compared to what you get when playing the same sound through the PC. Apple Computers may have done many things to hold back the GS, but the low pass filter was NOT one of them. > Are you also saying the GS is closely comparable to a CD-player >for audio, is this what your claiming? If you are, then this debate >is starting is shift from a technical discussion to a comedic one. No. However, the sound coming from a GS is quite good. CD players have low pass filters, btw. I've worked out a system to get clean, long samples to the GS. Digitize on a Mac or PC at 8-bit 44kHz. Save and transfer on a Zip drive, hard drive, or null-modem over to an HFS volume on the GS (if using Zip drive with PC disk, use MUG!). Use Longplay or Oversampler to play the sample. There's no loss in quality compared to playing the same sample on the PC. The low pass filter is a good thing. -Scott G. Subject: Re: Q: Applied Engineering Sound Card From: Eric Jacobs Date: 1997/03/30 Message-ID: <333EFE15.7B81@no.no> Newsgroups: comp.sys.apple2 [More Headers] [Subscribe to comp.sys.apple2] MJMahon wrote: > > There ain't no such thing as a free lunch--and you can't do better > than the Nyquist frequency! A lowpass simply acknowledges > reality and makes for a proper design. > > -michael > > Email: mjmahon@aol.com > Home page: http://members.aol.com/MJMahon/ Well said. And it might also be worthy to note that even if you don't have the low-pass filter, putting that signal into an audio amp and a speaker is definitely going to cut out those high frequencies. The low pass filter simply makes for the most accurate waveform on a 'scope. It does very little to the audible quality of the sample. I think much of this confusion results from the ambiguity of kHz, which can either refer to "thousands of samples per second" (sampling rate) or "thousands of cycles per second" (which is frequency.) You can't sample a 22 kHz frequency, at 22 thousand samples per second. You're asking to represent this: | _____ |/ \ |-------\-------/-- | \_____/ | ^ one cycle ^ in one digital sample! It doesn't make sense to put a whole cycle of anything into one digital number, whether it's an 8-bit or a 16-bit. You'll just get zero. You'll have more success if you try to sample that frequency at 44 kHz. Then you'll get two samples per cycle. This will at least give -some- variation in the sample. You'll get +1,-1,+1,-1,+1,-1,.. etc. This is of course, a square wave, which is a very poor approximation for the sine wave it is intended to represent. Unless you add the low pass filter. The low pass filter will cut out those excess harmonics above 22 kHz, transforming the square wave output from the DAC into a (relatively) smooth sine curve. The bottom line is this: in digital sampling and playback, any output frequency above 1/2 the sampling rate is distortion and needs to be filtered out for the most accurate result. In this example, the sampling rate was 44 kHz and any frequencies above 22 kHz are extraneous, introduced by the digital sampling process. Even the 26 kHz low pass filter in the GS may be bit excessive. Humans can't hear anything above about 20 kHz or so. The whine you sometimes hear from TV's scan circuitry is 15.7 kHz. Most of the useful audio we hear is way, way below that. So the 26 kHz low pass filter on the GS motherboard wasn't put there to lower the sound quality. It's merely part of proper digital sound design. Other computers can get away without the filter because they expect the audio will be fed into an audio amp or mixer, which will cut off the high frequencies anyway. Or maybe they were just engineered by aliens from outer space who have exceptionally high frequency vocal cords. :) As a human, I find the GS serves me well. As for those OTHER machines, .. well.. -ej <<<