mirror of
https://github.com/KevinMidboe/spotify-downloader.git
synced 2025-10-29 18:00:15 +00:00
Embed comment metadata in .m4a
This commit is contained in:
@@ -29,7 +29,8 @@ M4A_TAG_PRESET = { 'album' : '\xa9alb',
|
||||
'albumart' : 'covr',
|
||||
'copyright' : 'cprt',
|
||||
'tempo' : 'tmpo',
|
||||
'lyrics' : '\xa9lyr' }
|
||||
'lyrics' : '\xa9lyr',
|
||||
'comment' : '\xa9cmt' }
|
||||
|
||||
TAG_PRESET = {}
|
||||
for key in M4A_TAG_PRESET.keys():
|
||||
|
||||
@@ -98,6 +98,7 @@ class EmbedMetadata:
|
||||
audiofile = MP4(music_file)
|
||||
self._embed_basic_metadata(audiofile, preset=M4A_TAG_PRESET)
|
||||
audiofile[M4A_TAG_PRESET['year']] = meta_tags['year']
|
||||
audiofile[M4A_TAG_PRESET['comment']] = meta_tags['external_urls']['spotify']
|
||||
if meta_tags['lyrics']:
|
||||
audiofile[M4A_TAG_PRESET['lyrics']] = meta_tags['lyrics']
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user