MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / totalSamples

Method totalSamples

source/core/StarAudio.cpp:438–444  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

436 }
437
438 uint64_t totalSamples() {
439 #ifdef STAR_STREAM_AUDIO
440 return m_device->size() / 2 / m_channels;
441 #else
442 return m_memoryFile.dataSize() / 2 / m_channels;
443 #endif
444 }
445
446 void seekTime(double time) {
447 seekSample((uint64_t)(time * m_sampleRate));

Callers

nothing calls this directly

Calls 2

sizeMethod · 0.45
dataSizeMethod · 0.45

Tested by

no test coverage detected