There were always minor (or major) issues in my previous HD restores of the GoldenEye 007 OST.
I’ve spent the past 2 months working day-in and day-out on a tool I call Nintendo Synthy-4 whose job is to render Nintendo 64 music the way Nintendo 64 did, but with high-resolution versions of all of its routines.
I’ve been debugging the games and copying every routine exactly, taking care of every little detail. For example, when you change a track’s volume to 0, it takes 4 samples to reach 0 volume.
And here’s the exact vibrato routine (except in 64-bit instead of 32-bit):
/**
* Gets the vibrato depth given the game's 0-255 value.
*
* \param _ui8Val The value to convert.
* \return Returns the converted vibrato depth.
*/
static double VibratoDepthToReal( uint8_t _ui8Val ) {
return std::pow( 1.030992984771728515625f, _ui8Val );
}
void Set( uint8_t _ui8Rate, uint8_t _ui8Depth, uint8_t _ui8Delay, uint32_t _uiMasterSamplingRate ) {
dDepth = VibratoDepthToReal( _ui8Depth );
tbDelay.SetRate( ((1.0 / 30.0 / 2.0) * _ui8Delay) * _uiMasterSamplingRate );
tbRate.SetRate( ((1.0 / 30.0 / 2.0) * (259 - _ui8Rate)) * _uiMasterSamplingRate );
}
/**
* Gets the current vibrato depth.
*
* \return Returns the current vibrato depth.
*/
double Value() const {
if ( dDepth ) {
double dTmp = std::sin( tbRate.Time() * NS4_TWO_PI ) * dDepth;
// The cast is only a performance hack by the game, so removing it could be an “as-intended” routine with full precision.
double dRate = std::pow( 1.00057780742645263671875f, static_cast<int32_t>(dTmp / 2.0) );
return dRate;
}
return 1.0;
}
Nintendo Synthy-4 has a huge focus on accuracy, and that goes for the timing as well. I’ve taken measures to ensure it is always sample-accurate and never drifts.
The real game will trigger all of the notes on a tick starting on the same sample, but the time between ticks can vary.
Nintendo Synthy-4 is an offline renderer, so it can take as much time as it needs to render the perfect result. Every note starts on exactly the correct sample, no matter how long the recording is.
It does not accumulate drift either.
For a computer, (1/7.0)+(1/7.0)+(1/7.0)+(1/7.0)+(1/7.0)+(1/7.0)+(1/7.0) == 0.9999999999999997779553950749686919152736663818359375.
But Nintendo Synthy-4 handles all timers like this: 1/7, 2/7, 3/7, 4/7, 5/7, 6/7, 7/7, etc. This means that tiny inaccuracies are not accumulated. Every single sample in the final result is as accurate as every other sample.
I’ve had to use approximations for a lot of things before, but now even the reverb is accurate, with one difference.
This is the actual game’s reverb taps:
(https://i.imgur.com/phGM3ov.png)
Notice it drifts away from 0 toward the end. That is undesirable so I filtered that back into a nice clean reverb. I also eliminated the artifacts that cause major buzzing.
So what you get is the exact reverb but filtered to sound nice and clean.
So this is a truly accurate HD restore of GoldenEye 007 (48 KHz/32-bit):
https://www.youtube.com/playlist?list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce (https://www.youtube.com/playlist?list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce)
Samples:
https://www.youtube.com/watch?v=7qacI0HkjrY&list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce&index=9 (https://www.youtube.com/watch?v=7qacI0HkjrY&list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce&index=9)
https://www.youtube.com/watch?v=vlrr1SYRXew&list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce&index=51 (https://www.youtube.com/watch?v=vlrr1SYRXew&list=PLWsnao9n727PLCC-QTWwhYhEdqXd5GPce&index=51)
And from Perfect Dark:
https://www.dropbox.com/s/3ia8dwsii0p4d0b/093%20Alien%20Conflict.wav?dl=0 (https://www.dropbox.com/s/3ia8dwsii0p4d0b/093%20Alien%20Conflict.wav?dl=0)
https://www.dropbox.com/s/memh7nhj8moacdj/092%20Maian%20Tears.wav?dl=0 (https://www.dropbox.com/s/memh7nhj8moacdj/092%20Maian%20Tears.wav?dl=0)
https://www.dropbox.com/s/u93d43skg7ytlvs/065%20Deep%20Sea-%20Nullify%20Threat.wav?dl=0 (https://www.dropbox.com/s/u93d43skg7ytlvs/065%20Deep%20Sea-%20Nullify%20Threat.wav?dl=0)
Enjoy!
L. Spiro