Map "popularity meter" of ID3v2 tags to the generic rating field

See https://github.com/Martchus/tageditor/issues/84
This commit is contained in:
Martchus 2022-06-15 23:50:15 +02:00
parent 7a70a8e098
commit 1457dec990
3 changed files with 9 additions and 1 deletions

View File

@ -10,7 +10,7 @@ set(META_APP_URL "https://github.com/${META_APP_AUTHOR}/${META_PROJECT_NAME}")
set(META_APP_DESCRIPTION "C++ library for reading and writing MP4 (iTunes), ID3, Vorbis, Opus, FLAC and Matroska tags")
set(META_VERSION_MAJOR 11)
set(META_VERSION_MINOR 2)
set(META_VERSION_PATCH 1)
set(META_VERSION_PATCH 2)
set(META_REQUIRED_CPP_UNIT_VERSION 1.14.0)
set(META_ADD_DEFAULT_CPP_UNIT_TEST_APPLICATION ON)

View File

@ -79,6 +79,8 @@ std::uint32_t convertToShortId(std::uint32_t id)
return sRemixedBy;
case lCopyright:
return sCopyright;
case lRating:
return sRating;
case lISRC:
return sISRC;
default:
@ -145,6 +147,8 @@ std::uint32_t convertToLongId(std::uint32_t id)
return lRemixedBy;
case sCopyright:
return lCopyright;
case sRating:
return lRating;
case sISRC:
return lISRC;
default:

View File

@ -307,6 +307,8 @@ KnownField Id3v2Tag::internallyGetKnownField(const IdentifierType &id) const
return KnownField::OriginalReleaseDate;
case lMood:
return KnownField::Mood;
case lRating:
return KnownField::Rating;
case lISRC:
return KnownField::ISRC;
case sAlbum:
@ -349,6 +351,8 @@ KnownField Id3v2Tag::internallyGetKnownField(const IdentifierType &id) const
return KnownField::RemixedBy;
case sCopyright:
return KnownField::Copyright;
case sRating:
return KnownField::Rating;
case sISRC:
return KnownField::ISRC;
default: