Linked by Thom Holwerda on Tue 15th May 2018 20:34 UTC
Games

This is just a slightly modified version of the standard DOSBOX emulator. I have just hacked in my own shader which emulates some aspects of old CRT monitors, as I prefer to play emulated games with such a filter, and the built-in dosbox filters are not to my taste. I made this because I wanted it myself, but since I have it I thought I'd share it. There's probably lots of things which could be done better, but it's good enough for my needs right now, so leaving it like this for now.

Not a major news item, obviously, and just one among countless contributions to open source that pass by unnoticed every day, but every now and then, it seems only prudent to highlight one.

Order by: Score:
Bit OT, but ...
by WorknMan on Tue 15th May 2018 21:33 UTC
WorknMan
Member since:
2005-11-13

Is there something like this that exists in the audio world, sort of a filter that makes music sound like it's coming from an FM radio? Not the static, but the... well, whatever the hell FM does to music that makes it sound like FM ;)

I try to listen to 80's music on streaming, but having grown up listening to it mostly on FM radio, it sounds too 'clean'. Surely, I'm not the only one? I figure an audience interested in dirtying up an image by applying a CRT filter to it might appreciate where I'm coming from.

Edited 2018-05-15 21:34 UTC

Reply Score: 3

RE: Bit OT, but ...
by graffias79 on Tue 15th May 2018 21:50 UTC in reply to "Bit OT, but ..."
graffias79 Member since:
2013-04-11

I believe it would have to have some dynamic range compression added and a frequency cutoff around 14 KHz to emulate FM. Also, maybe a few db of noise floor.

Reply Score: 3

RE: Bit OT, but ...
by bartgrantham on Tue 15th May 2018 22:38 UTC in reply to "Bit OT, but ..."
bartgrantham Member since:
2011-12-31

I've contemplated this one a bit, myself. As a first approximation, as graffias79 noted they'd have done some compression and there's a lowpass filter below 15Khz.

But that's just for the L+R signal. A big part of why FM sounds the way it does is the stereo image. The reconstruction signal, L-R, is amplitude modulated to a 38Khz carrier, and there's a 19KHz pilot tone used to reconstruct it. (this zany scheme allowed backwards compatibility with mono FM receivers, and these days there's data transmitted on the 57Khz carrier)

To directly emulate this you'd probably need to upsample your digital signal to a much higher sample rate (192Khz would probably work), do the L+R/L-R modulation/demodulation, and then downsample and output. I'm sure there's an analysis of the signal processing that would distill it into something substantially less computationally intensive, but the math is beyond me.

And besides the signal chains for transmission, radio stations have very carefully chosen signal chains to enhance the actual _sound_ to try to appeal the most to their audience. That stuff is generally black magic, and I'm sure radio engineers love to argue over the best systems as much as any other sound engineer.

Reply Score: 6

RE[2]: Bit OT, but ...
by WorknMan on Wed 16th May 2018 00:13 UTC in reply to "RE: Bit OT, but ..."
WorknMan Member since:
2005-11-13

I don't understand a bit of what you said, but it sounds complicated ;)

Reply Score: 2

RE[2]: Bit OT, but ...
by darknexus on Wed 16th May 2018 17:19 UTC in reply to "RE: Bit OT, but ..."
darknexus Member since:
2008-07-15

And just to make it more complicated, radio stations back then worked almost exclusively with analog source material, and chose their signal processing accordingly. This means you'll not likely find the same processing they've done, even if you get something that sounds very close, since analog and digital sources have different characteristics and artifacts. I don't remember if they played songs faster to make them shorter back then the way they do now, but if they did, you'd have to take that into account as well.

Reply Score: 1

RE: Bit OT, but ...
by zima on Fri 18th May 2018 00:27 UTC in reply to "Bit OT, but ..."
zima Member since:
2005-07-06

Ask on hydrogenaud.io forum - it's a supreme source of info on audio.

Reply Score: 2

Comment by ssokolow
by ssokolow on Tue 15th May 2018 22:14 UTC
ssokolow
Member since:
2010-01-21

I've never been a big fan of emulated scanlines. They always feel just as untrue to my supply of old CRTs as nearest neighbour fat-pixel scaling.

Aside from Inescapable (which has done a great job of creating a good CRT filter which doesn't rely on shaders), I've just given in to my laziness and resigned myself to either fat pixels or xBRZ.

http://www.magneticrealms.com/posts/2014/02/03/a-crt-filter-without...

Edited 2018-05-15 22:34 UTC

Reply Score: 1

RE: Comment by ssokolow
by Kochise on Wed 16th May 2018 01:34 UTC in reply to "Comment by ssokolow"
Kochise Member since:
2006-03-03

Saint, an Atari emulator, have one for quite a long time now :

http://leonard.oxg.free.fr/SC1425/SC1425.html

Reply Score: 3

RE[2]: Comment by ssokolow
by ssokolow on Thu 17th May 2018 01:08 UTC in reply to "RE: Comment by ssokolow"
ssokolow Member since:
2010-01-21

While I applaud the effort...

1. I'm a Linux user and don't run emulators under Wine if I can at all avoid it. (The main exception so far is the copy of Project64 I've been running for Donkey Kong 64, since my console has an undiagnosed reset problem and Mupen64Plus doesn't get along with DK64.)

2. I don't see any evidence that SainT is open-source. The accomplishment of accurate CRT emulation is of limited interest to me if it's locked into a single application and the developer didn't even go into as much detail as Inescapable's developer did.)

3. I have a strict policy about what is allowed to be closed-source on my system and emulators are not only not on the whitelist, they're actively on the blacklist because I rely on open-source emulation to serve as an isolation layer between the non-evolving codebases of old closed-source games and the evolving definition of "commodity hardware".

4. My only experience with the Atari ST is a 520STFM with a high-resolution B&W monitor that I grabbed one garbage day, which I haven't gamed on yet. (I've purchased a composite out cable and a PS/2 mouse adapter for it to get color graphics and non-keyboard cursor movement, but I still need to either find a way to write Atari ST floppies using the gear I have on hand or buy a drive emulator and some software.)

Reply Score: 1

RE[3]: Comment by ssokolow
by Kochise on Thu 17th May 2018 04:15 UTC in reply to "RE[2]: Comment by ssokolow"
Kochise Member since:
2006-03-03

Your "open-source only" dogma is yours. Closed source applications works well too, it's also a matter of confidence.

Reply Score: 3

RE[4]: Comment by ssokolow
by ssokolow on Thu 17th May 2018 22:38 UTC in reply to "RE[3]: Comment by ssokolow"
ssokolow Member since:
2010-01-21

Your "open-source only" dogma is yours. Closed source applications works well too, it's also a matter of confidence.


Let me restate it more clearly. I have an "'open-source only' dogma" for three very practical reasons:

1. Minimize the chance that I find myself running an emulator inside another emulator ten years down the road in order to keep using games/applications I've grown used to.

2. Maximize the trustworthiness of code with access to my user account at large.

3. Ensure that great things (like CRT emulation) can be shared across all relevant applications. (eg. how DOSBox and ScummVM offer pretty much the same selection of scalers.)

Edited 2018-05-17 22:40 UTC

Reply Score: 0

lots of forks, but I still use the original
by Rugxulo on Tue 15th May 2018 22:14 UTC
Rugxulo
Member since:
2007-10-09

DOSBox is such a stellar piece of software. It's been very successful. But I don't even use all the billions of forks, just the original. It was last updated about eight years ago, too (May 2010). I guess if it ain't broke, don't fix it!

Reply Score: 2

ssokolow Member since:
2010-01-21

DOSBox is such a stellar piece of software. It's been very successful. But I don't even use all the billions of forks, just the original. It was last updated about eight years ago, too (May 2010). I guess if it ain't broke, don't fix it!


Actually, they never stopped developing it... they just haven't made a release in eight years. That's part of the reason so many forks against the development version exist.

https://sourceforge.net/p/dosbox/code-0/HEAD/tree/dosbox/trunk/

Edited 2018-05-15 22:37 UTC

Reply Score: 2