MCPcopy Create free account
hub / github.com/MusicPlayerDaemon/MPD / sndfile_duration

Function sndfile_duration

src/decoder/plugins/SndfileDecoderPlugin.cxx:126–130  ·  view source on GitHub ↗

* Converts a frame number to a timestamp (in seconds). */

Source from the content-addressed store, hash-verified

124 * Converts a frame number to a timestamp (in seconds).
125 */
126static constexpr SongTime
127sndfile_duration(const SF_INFO &info)
128{
129 return SongTime::FromScale<uint64_t>(info.frames, info.samplerate);
130}
131
132[[gnu::pure]]
133static SampleFormat

Callers 2

sndfile_stream_decodeFunction · 0.85
sndfile_scan_streamFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected