minor sound tweaks

This commit is contained in:
zeromus 2006-08-22 07:13:41 +00:00
parent 886085c9cb
commit a82608cd98
3 changed files with 12 additions and 11 deletions

View File

@ -3,7 +3,7 @@
#include "dsound.h"
#include <vector>
#define LATENCY_MS (50)
#define LATENCY_MS (100)
int voltbl[] = {

View File

@ -400,6 +400,7 @@ public:
int remain = buffers.length>>1;
dsout->unlock();
if(remain<44100/60) break;
//if(remain<44100*scale/256/60) break; ??
Sleep(1);
}
}

View File

@ -56,18 +56,18 @@ static uint64 ttime,ltime;
static void InitSpeedThrottle(void)
{
timeBeginPeriod(1);
SetThreadAffinityMask(GetCurrentThread(),1);
//timeBeginPeriod(1);
//SetThreadAffinityMask(GetCurrentThread(),1);
//
tmethod=0;
if(QueryPerformanceFrequency((LARGE_INTEGER*)&tfreq)) {
tmethod=1;
}
else tfreq=1000;
//tmethod=0;
//if(QueryPerformanceFrequency((LARGE_INTEGER*)&tfreq)) {
// tmethod=1;
//}
//else tfreq=1000;
tfreq<<=16; /* Adjustment for fps returned from FCEUI_GetDesiredFPS(). */
ltime = 0; //mbg
//tfreq<<=16; /* Adjustment for fps returned from FCEUI_GetDesiredFPS(). */
//ltime = 0; //mbg
}
///Resets the throttle timing. use this when the player releases the turbo