mirror of
https://github.com/halpz/re3.git
synced 2025-10-05 16:55:35 +00:00
@@ -587,16 +587,16 @@ cSampleManager::Initialise(void)
|
||||
}
|
||||
|
||||
nSampleBankMemoryStartAddress[SAMPLEBANK_MAIN] = (uintptr)malloc(nSampleBankSize[SAMPLEBANK_MAIN]);
|
||||
ASSERT(nSampleBankMemoryStartAddress[SAMPLEBANK_MAIN] != NULL);
|
||||
ASSERT(nSampleBankMemoryStartAddress[SAMPLEBANK_MAIN] != 0);
|
||||
|
||||
if ( nSampleBankMemoryStartAddress[SAMPLEBANK_MAIN] == NULL )
|
||||
if ( nSampleBankMemoryStartAddress[SAMPLEBANK_MAIN] == 0 )
|
||||
{
|
||||
Terminate();
|
||||
return false;
|
||||
}
|
||||
|
||||
nSampleBankMemoryStartAddress[SAMPLEBANK_PED] = (uintptr)malloc(PED_BLOCKSIZE*MAX_PEDSFX);
|
||||
ASSERT(nSampleBankMemoryStartAddress[SAMPLEBANK_PED] != NULL);
|
||||
ASSERT(nSampleBankMemoryStartAddress[SAMPLEBANK_PED] != 0);
|
||||
}
|
||||
|
||||
|
||||
|
@@ -150,9 +150,11 @@ CdStreamInit(int32 numChannels)
|
||||
ASSERT(0);
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef __linux__
|
||||
_gdwCdStreamFlags = O_RDONLY | O_NOATIME;
|
||||
|
||||
#else
|
||||
_gdwCdStreamFlags = O_RDONLY;
|
||||
#endif
|
||||
// People say it's slower
|
||||
/*
|
||||
if ( fsInfo.f_bsize <= CDSTREAM_SECTOR_SIZE )
|
||||
@@ -400,9 +402,12 @@ void *CdStreamThread(void *param)
|
||||
if (gCdStreamThreadStatus == 0){
|
||||
gCdStreamThreadStatus = 1;
|
||||
#endif
|
||||
|
||||
#ifdef __linux__
|
||||
pid_t tid = syscall(SYS_gettid);
|
||||
int ret = setpriority(PRIO_PROCESS, tid, getpriority(PRIO_PROCESS, getpid()) + 1);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
// spurious wakeup or we sent interrupt signal for flushing
|
||||
if(pChannel->nSectorsToRead == 0)
|
||||
|
@@ -209,7 +209,11 @@ double
|
||||
psTimer(void)
|
||||
{
|
||||
struct timespec start;
|
||||
#ifdef __linux__
|
||||
clock_gettime(CLOCK_MONOTONIC_RAW, &start);
|
||||
#else
|
||||
clock_gettime(CLOCK_MONOTONIC, &start);
|
||||
#endif
|
||||
return start.tv_sec * 1000.0 + start.tv_nsec/1000000.0;
|
||||
}
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user