metaspu: have it compiled under gcc too

Based on patches from Tobias Jakobi (liquidacid) in #3250391
This commit is contained in:
riccardom 2011-04-09 17:09:26 +00:00
parent 79684686c3
commit 74b8df277c
3 changed files with 15 additions and 8 deletions

View File

@ -83,7 +83,7 @@ static const int SndOutVolumeShift = 0;
////static const int SampleRate = 48000;
//static const int SampleRate = 44100;
//edit - nitsuja: make it use the global sample rate define
#include "..\SPU.h"
#include "../SPU.h"
static const int SampleRate = DESMUME_SAMPLE_RATE;
extern int FindOutputModuleById( const wchar_t* omodid );

View File

@ -18,12 +18,18 @@
//#include "Global.h"
#include <math.h>
#include "types.h"
#include "SoundTouch/SoundTouch.h"
#include "SndOut.h"
//#include "SoundTouch/WavFile.h"
#include "win32/Dialogs.h"
#ifdef HAVE_LIBSOUNDTOUCH
#include <SoundTouch.h>
#else
#include "SoundTouch/SoundTouch.h"
#endif
#ifdef _WINDOWS
#include "win32/Dialogs.h"
#endif
static soundtouch::SoundTouch* pSoundTouch = NULL;
@ -313,7 +319,9 @@ void SndBuffer::soundtouchInit()
pSoundTouch->setSetting( SETTING_USE_QUICKSEEK, 0 );
pSoundTouch->setSetting( SETTING_USE_AA_FILTER, 0 );
#ifdef _WINDOWS
SoundtouchCfg::ApplySettings( *pSoundTouch );
#endif
pSoundTouch->setTempo(1);

View File

@ -24,8 +24,7 @@
#include <assert.h>
//for pcsx2 method
//(havent bothered to get it compiling in gcc yet)
#ifdef _MSC_VER
#if defined(_MSC_VER) || defined(HAVE_LIBSOUNDTOUCH)
#include "SndOut.h"
#endif
@ -466,7 +465,7 @@ private:
}; //NitsujaSynchronizer
#ifdef _MSC_VER
#if defined(_MSC_VER) || defined(HAVE_LIBSOUNDTOUCH)
class PCSX2Synchronizer : public ISynchronizingAudioBuffer
{
public:
@ -513,9 +512,9 @@ ISynchronizingAudioBuffer* metaspu_construct(ESynchMethod method)
{
case ESynchMethod_N: return new NitsujaSynchronizer();
case ESynchMethod_Z: return new ZeromusSynchronizer();
#ifdef _MSC_VER
#if defined(_MSC_VER) || defined(HAVE_LIBSOUNDTOUCH)
case ESynchMethod_P: return new PCSX2Synchronizer();
#endif
#endif
default: return NULL;
}
}