aboutsummaryrefslogtreecommitdiff
path: root/source/dsp2emu.c
diff options
context:
space:
mode:
authorJoão Silva2017-01-14 23:08:50 +0000
committerJoão Silva2017-01-14 23:08:50 +0000
commit3b8323853f4eeddb61398e77c51bb2349f430227 (patch)
tree55cb980be4bf5bf93041392470637d78c73b4854 /source/dsp2emu.c
parentd59c856fbf576daa91fa4a8bade38d97b4edbbe4 (diff)
downloadsnes9x2005-3b8323853f4eeddb61398e77c51bb2349f430227.tar.gz
snes9x2005-3b8323853f4eeddb61398e77c51bb2349f430227.tar.bz2
snes9x2005-3b8323853f4eeddb61398e77c51bb2349f430227.zip
Removed a LOT of useless stuff.
Diffstat (limited to 'source/dsp2emu.c')
-rw-r--r--source/dsp2emu.c42
1 files changed, 0 insertions, 42 deletions
diff --git a/source/dsp2emu.c b/source/dsp2emu.c
index 453ab6a..d5a9855 100644
--- a/source/dsp2emu.c
+++ b/source/dsp2emu.c
@@ -208,45 +208,3 @@ void DSP2_Op0D()
}
#endif
-
-#if 0 // Probably no reason to use this code - it's not quite bit accurate and it doesn't look as good as Overload's algorithm
-
-void DSP2_Op0D()
-{
- // Float implementation of Neviksti's algorithm
- // This is the right algorithm to match the DSP2 bits but the precision
- // of the PC float does not match the precision of the fixed point math
- // on the DSP2 causing occasional one off data mismatches (which should
- // be no problem because its just a one pixel difference in a scaled image
- // to be displayed).
-
- float multiplier;
- float pixloc;
- int i, j;
- uint8_t pixelarray[512];
-
- if (DSP2Op0DInLen <= DSP2Op0DOutLen)
- multiplier = (float) 1.0;
- else
- multiplier = (float)((DSP2Op0DInLen * 2.0) / (DSP2Op0DOutLen * 2.0 + 1.0));
-
- pixloc = 0.0;
- for (i = 0; i < DSP2Op0DOutLen * 2; i++)
- {
- // j = (int)(i * multiplier);
- j = (int) pixloc;
-
- if (j & 1)
- pixelarray[i] = DSP1.parameters[j >> 1] & 0x0f;
- else
- pixelarray[i] = (DSP1.parameters[j >> 1] & 0xf0) >> 4;
-
- pixloc += multiplier; // use an add in the loop instead of multiply to increase loop speed
- }
-
- for (i = 0; i < DSP2Op0DOutLen; i++)
- DSP1.output[i] = (pixelarray[i << 1] << 4) | pixelarray[(i << 1) + 1];
-}
-
-#endif
-