Sound mixing question - "authentic" downsampling?

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Sound mixing question - "authentic" downsampling?

Post by wildweasel »

Here's something I've been puzzling over for a while that you sound engineering folks (like Nash, perhaps?) might be able to help me with. I keep having the thought to take one of my mods and downsample the sounds to 11 KHz, 8-bit mono, to make it a bit more "authentic" to a typical 1994-era DOS game. The thing is, modern audio editing programs seem to be "too good" at this sort of thing, using clever interpolation and things like that to retain the quality of the sounds at low bitrates.

What I have to wonder, though, is how did they do it in the old days? The default Doom.wad sounds, the VOC files in Duke 3D and Shadow Warrior, and numerous others have a characteristic "crispness" to them that I can't seem to replicate using my tool of choice (GoldWave). What do I need to do?
Blzut3
 
 
Posts: 3211
Joined: Wed Nov 24, 2004 12:59 pm
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Blzut3 »

What's happening is modern tools run your wave through a low pass filter before resampling. This is because digital waves are capable of losslessly representing any frequency below their nyquist (half the sampling rate), but any frequency above will be aliased. That aliasing is probably the source of the quality issues in old games. Not really clever interpolation, they just use the correct algorithm. :P

Can't say I can name a tool that doesn't do filtering, so that's about as much help as I can be. The old algorithm is probably discard every n-th sample, so it would probably be easy enough to make a program.

Edit: Actually, I just noticed Audacity comes with a plugin called Decimator which does just that. Or rather it simulates it at the current sample rate. Then you can down sample to save space.
User avatar
leileilol
Posts: 4449
Joined: Sun May 30, 2004 10:16 am
Preferred Pronouns: She/Her
Location: GNU/Hell

Re: Sound mixing question - "authentic" downsampling?

Post by leileilol »

Some had horribly aliased sound (Duke3D, Jagged Alliance) and to achieve that I used Secret Rabbit Code resampling within Foobar2000 with it set to Nearest Neighbor... you could experiment with that.

I don't use anything better than Cool Edit 96 for sound editing - and that's more of a recent upgrade so I could use it on XP/7! Before that it was all Cool Edit 1.31...
User avatar
Nash
 
 
Posts: 17501
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Nash »

I've never had to downsample stuff for work before (I always record at the target sample of 44.1 KHz) but as Blzut3 has already mentioned; it's just a matter of bypassing any filters your audio program is applying during a downsample. Kind of like resizing a picture down in Photoshop but using nearest neighbour instead of bilinear.
User avatar
revo794
Posts: 158
Joined: Sun Dec 30, 2012 9:33 am

Re: Sound mixing question - "authentic" downsampling?

Post by revo794 »

The closest thing I've found yet is using Decimator plug-in for Audacity. That's how it's used like. Note that the sampling will still remain the same. There's also a Smooth Decimator plug-in.
User avatar
Arch
Posts: 491
Joined: Thu Nov 10, 2011 12:06 pm
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Arch »

Weasel, I made some tests with gun sounds and ended up with something here. What I did was cut highs and lows, boost a mid frequency (640hz, in case), and changed pitch. Changing pitch is what really screws it, if abused, the sound gets distorted as an atari game sound.

I attached my tests here, it's not an authentic downsampling, but maybe resembles what you're looking for.
Attachments
shot tests.zip
(10.61 KiB) Downloaded 25 times
User avatar
Marrub
 
 
Posts: 1202
Joined: Tue Feb 26, 2013 2:48 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Arch Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Marrub »

I swear this question is tormenting me. Decimator doesn't change the actual rate due to it being a Nyquist plugin and as such doesn't really decrease the filesize that much, SRC's author is too much of a dickbag to actually update the foobar plugin, and I can't find any programs that don't friggin' filter when downsampling.
Blzut3
 
 
Posts: 3211
Joined: Wed Nov 24, 2004 12:59 pm
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Blzut3 »

Decimator doesn't change the actual rate, but it should prepare the wave such that when filtering on down sample nothing is "lost." Easy way to see this would be to generate a sine wave above the down sampled nyquist, decimate, and resample. You should get something other than silence which is your aliased wave.
User avatar
Marrub
 
 
Posts: 1202
Joined: Tue Feb 26, 2013 2:48 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Arch Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Marrub »

Yeah, but that isn't really the problem. Problem is that it ends up soundin' like crap due to what I'm assuming is filtering which it might not be cause I'm not very educated on sound.
http://puu.sh/5x6zx.wav - Original sample
http://puu.sh/5x6BD.wav - Original resampled
http://puu.sh/5x6An.wav - Decimated
http://puu.sh/5x6AY.wav - Decimated and resampled
Blzut3
 
 
Posts: 3211
Joined: Wed Nov 24, 2004 12:59 pm
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Blzut3 »

Well keep in mind the whole idea of resampling without the filter is to make it sound like crap. :P

The fourier spectrum of the input doesn't have a whole lot of sound above the nyquist so the aliased wave isn't that prominent.
User avatar
Marrub
 
 
Posts: 1202
Joined: Tue Feb 26, 2013 2:48 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Arch Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Marrub »

Blzut3 wrote:Well keep in mind the whole idea of resampling without the filter is to make it sound like crap. :P
True, but at least it doesn't sound like this
http://puu.sh/5x9g8.wav (warning:loud)
User avatar
TheMightyHeracross
Posts: 2100
Joined: Sun Aug 18, 2013 9:41 am
Location: Philadelphia, PA

Re: Sound mixing question - "authentic" downsampling?

Post by TheMightyHeracross »

Whatever you did sounds good for making things sound like they're being played on a crappy radio. :P
User avatar
cocka
Posts: 1520
Joined: Sat Jul 02, 2011 7:21 am
Location: Hungary

Re: Sound mixing question - "authentic" downsampling?

Post by cocka »

What do I need to do?
Just a tip: How about using sndrec32.exe? :)
User avatar
Marrub
 
 
Posts: 1202
Joined: Tue Feb 26, 2013 2:48 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Arch Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by Marrub »

cocka wrote:
What do I need to do?
Just a tip: How about using sndrec32.exe? :)
THANKS FOR THE TIP, NOW I DON'T HAVE TO PUNCH MYSELF FOR HAVING NOTHING THAT RESAMPLES WITHOUT FILTERS.
http://puu.sh/5xUHe.wav
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Re: Sound mixing question - "authentic" downsampling?

Post by wildweasel »

Hmm. I wonder if my current installation of Windows 3.1 in DOSBox actually bothered to install Sound Recorder...
Locked

Return to “Editing (Archive)”