Added albumArtist field memeber to Song model. Automatically apply disc value 1 for song's metadata that have an empty disc field. Switched from TagLib::FileRef to TagLib::MPEG::File

This commit is contained in:
kdeng00
2019-11-04 22:26:03 -05:00
parent c7bbdfe581
commit 9b4a0db67a
16 changed files with 236 additions and 231 deletions
+2 -1
View File
@@ -128,7 +128,7 @@ void SongManager::saveSong(model::Song& song)
saveSongTemp(song);
utility::MetadataRetriever meta;
auto data = std::move(song.data);
song = meta.retrieveMetadata(song.songPath);
song = meta.retrieveMetadata(song);
song.data = std::move(data);
saveMisc(song);
@@ -146,6 +146,7 @@ void SongManager::printSong(const model::Song& song)
std::cout << "\nsong" << std::endl;
std::cout << "title: " << song.title << std::endl;
std::cout << "artist: " << song.artist << std::endl;
std::cout << "album artist: " << song.albumArtist << std::endl;
std::cout << "album: " << song.album << std::endl;
std::cout << "genre: " << song.genre << std::endl;
std::cout << "duration: " << song.duration << std::endl;