Mercurial > hg > svcore
diff data/fileio/WavFileReader.cpp @ 1592:f8e3dcbafb4d bqaudiostream
Implement title/maker in wav readers; extra handling of supported-ness for file types
author | Chris Cannam |
---|---|
date | Mon, 21 Jan 2019 13:16:17 +0000 |
parents | 954d0cf29ca7 |
children | ce185d4dd408 |
line wrap: on
line diff
--- a/data/fileio/WavFileReader.cpp Mon Jan 21 11:45:51 2019 +0000 +++ b/data/fileio/WavFileReader.cpp Mon Jan 21 13:16:17 2019 +0000 @@ -95,6 +95,15 @@ if (m_normalisation != Normalisation::None && !m_updating) { m_max = getMax(); } + + const char *str = sf_get_string(m_file, SF_STR_TITLE); + if (str) { + m_title = str; + } + str = sf_get_string(m_file, SF_STR_ARTIST); + if (str) { + m_maker = str; + } } SVDEBUG << "WavFileReader: Filename " << m_path << ", frame count " << m_frameCount << ", channel count " << m_channelCount << ", sample rate " << m_sampleRate << ", format " << m_fileInfo.format << ", seekable " << m_fileInfo.seekable << " adjusted to " << m_seekable << ", normalisation " << int(m_normalisation) << endl;