Emulation that enhances the originals

Página 2/5
1 | | 3 | 4 | 5

Por syn

Prophet (2069)

Imagen del syn

12-01-2015, 23:59

That snatcher mp3 sounds good! The drums really add something to the music Big smile

Im unsure about the panning, it feels the main melody is too much to the right. Maybe get rid of the channel panning and only use the pseudo-stereo (that delay thingy).

Next stop: opll/YM241 drums? Smile anyway good job, keep us posted on your updates! Smile

Por erikd

Master (255)

Imagen del erikd

13-01-2015, 13:51

Thanks for listening Smile
The panning is currently a generic configuration across all games. Sometimes the main melody is more on the right, other times it's more on the left, etc.
I think generally it works quite alright, so I'd rather keep the panning in place because it's imho the most important enhancement to the audio, even if it's not perfect on some tracks.
Just having the delay stereo without panning won't really work I think.

What I am considering playing with is adding an option that will filter the audio too, based on the stereo positioning. That way, I could perhaps make the panning less extreme while creating a more natural binaural simulation.

I guess the FM drums are by far the easiest to replace as they are sort of hardwired into the chips, so after I got the drums working with most other Konami games (that have drums), I suppose could work on replacing FM drums (which indeed sound awful).

Por NYYRIKKI

Enlighted (5889)

Imagen del NYYRIKKI

13-01-2015, 14:56

One thing that you could also try is to play the sounds double, but with a little different frequency... It also gives quite a neat effect Smile

Por erikd

Master (255)

Imagen del erikd

13-01-2015, 19:37

NYYRIKKI, yeah that can sound cool too Smile
That'd really have to be done per song though as I could imagine it can sound quite bad in other songs.
That said, what I already do is have the 2 SCCs (the left and right one) slightly detuned to enhance the stereo effect.

Por erikd

Master (255)

Imagen del erikd

13-01-2015, 19:54

What I should probably also really do is implement some oversampling on the SCCs; it would really clean up the sound I think.

Por Grauw

Ascended (10156)

Imagen del Grauw

13-01-2015, 20:23

Even simple linear interpolation would already be better than what the SCC does Smile. It does no interpolation at all. That said, the jagged output of the SCC introduces high frequencies without which you might lose “character”. It’s worth a try though.

Por erikd

Master (255)

Imagen del erikd

13-01-2015, 20:32

What kind of interpolation are you thinking of? Just interpolating between samples? Because that would really alter the sound and probably make it sound duller I think.
What I'm thinking of is just oversampling to reduce aliasing, nothing more.

Por Grauw

Ascended (10156)

Imagen del Grauw

13-01-2015, 20:54

Oversampling to reduce aliasing, ok sure, but existing emulators already do that afaik.

SCC output looks like this (just grabbed a random pic off the net):

All these shelves in the waveform add a lot of “rogue” high frequency harmonics. Simple linear interpolation would already get rid of a lot of them. Could also do proper upsampling. I wonder how that would sound, less raw and more pure I guess, but would that make the SCC lose its character? Or just make it better :).

Por erikd

Master (255)

Imagen del erikd

13-01-2015, 21:08

Ah, I see what you're getting at; the lack of resolution below niquist, adding more harmonics.
I don't want to take that away because that's what the original composers probably composed their tracks on. That stuff doesn't bother me, but the aliasing that's happening with some high frequency sounds with lots of harmonics does (especially in the SD-Snatcher intro like for example that 'harmonica'-like sound there).

So I guess I'll just have to add what other emulators are apparently doing already.
The existing MSX emulators like OpenMSX and BlueMSX are much more advanced than my own emulator (it really can't conpare with those), so I'm sure I can learn a lot there.

Por Grauw

Ascended (10156)

Imagen del Grauw

13-01-2015, 22:21

To test I just locally modified KSS-X to do linear interpolation (hope I got that right)…

The SCC mostly sounds much thinner, not an improvement at all :). Well, now I know!

diff --git a/src/kss/kssObject/device/emu2212.c b/src/kss/kssObject/device/emu2212.c
index aa50615..7e2da4b 100755
--- a/src/kss/kssObject/device/emu2212.c
+++ b/src/kss/kssObject/device/emu2212.c
@@ -189,7 +189,14 @@ calc (SCC * scc)
     {
       scc->phase[i] = ((scc->count[i] >> (GETA_BITS)) + scc->offset[i]) & 0x1F;
       if(!(scc->mask&SCC_MASK_CH(i)))
-		  mix += ((((e_int8) (scc->wave[i][scc->phase[i]]) * (e_int8) scc->volume[i]))) >> 4;		
+      {
+          e_int8 sample = scc->wave[i][scc->phase[i]];
+
+          e_int32 deltaSample = scc->wave[i][scc->phase[i + 1 & 31]] - scc->wave[i][scc->phase[i]];
+          sample += deltaSample * (scc->count[i] & ((1 << GETA_BITS) - 1)) >> GETA_BITS;
+          
+          mix += ((((e_int8) sample * (e_int8) scc->volume[i]))) >> 4;
+      }
     }
 	  
   }
Página 2/5
1 | | 3 | 4 | 5