97 |
// number of '0' samples (silence samples) behind the official buffer |
// number of '0' samples (silence samples) behind the official buffer |
98 |
// border, to allow the interpolator do it's work even at the end of |
// border, to allow the interpolator do it's work even at the end of |
99 |
// the sample. |
// the sample. |
100 |
::gig::buffer_t buf = pSample->LoadSampleDataWithNullSamplesExtension((pEngine->pAudioOutputDevice->MaxSamplesPerCycle() << MAX_PITCH) + 3); |
dmsg(3,("Caching whole sample (sample name: \"%s\", sample size: %d)\n", pSample->pInfo->Name.c_str(), pSample->SamplesTotal)); |
101 |
|
const uint silenceSamples = (pEngine->pAudioOutputDevice->MaxSamplesPerCycle() << MAX_PITCH) + 3; |
102 |
|
::gig::buffer_t buf = pSample->LoadSampleDataWithNullSamplesExtension(silenceSamples); |
103 |
dmsg(4,("Cached %d Bytes, %d silence bytes.\n", buf.Size, buf.NullExtensionSize)); |
dmsg(4,("Cached %d Bytes, %d silence bytes.\n", buf.Size, buf.NullExtensionSize)); |
104 |
} |
} |
105 |
else { // we only cache NUM_RAM_PRELOAD_SAMPLES and stream the other sample points from disk |
else { // we only cache NUM_RAM_PRELOAD_SAMPLES and stream the other sample points from disk |