Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does it support lyrics? #1974

Open
1 task done
ptrzs3 opened this issue Jan 10, 2024 · 5 comments
Open
1 task done

Does it support lyrics? #1974

ptrzs3 opened this issue Jan 10, 2024 · 5 comments
Labels
question Question, clarification, discussion

Comments

@ptrzs3
Copy link

ptrzs3 commented Jan 10, 2024

Has the question been asked before?

  • I have searched the existing issues

Question

I searched existed questions to find out if music-metadata support parse embeded lyrics while there isn't results.
code like this below, this.lyrics is always null while the .mp3 file does exist embeded lyrics:

  async getMetadata() {
    this.lyrics = mm.common.lyrics ? mm.common.lyrics : ['null']
  }

To avoid the .mp3 file is broken, I tried other npm library like id3-parser, it can parse the embeded lyrics

@ptrzs3 ptrzs3 added the question Question, clarification, discussion label Jan 10, 2024
@ptrzs3
Copy link
Author

ptrzs3 commented Jan 10, 2024

Add supplementary note

const mm = await parseFile(this.filePath, { duration: true })

@ffxsam
Copy link

ffxsam commented May 17, 2024

Would love to see lyrics support! It's an official ID3 tag.

@Borewit
Copy link
Owner

Borewit commented May 17, 2024

There is some lyrics support present, including the ID3v2 / ID3v2 SYLT tag.

Unit test covering this:

t.deepEqual(metadata.common.lyrics, [
'The way we\'re living makes no sense',
'Take me back to the age of innocence',
'I wanna go back then',

Tag mapping (I know, very hard to scroll to the right side of the table): here.

But there maybe lyric standards which are not support yet, such as Lyrics3 v2.00, which I believe is requested here: #264.

@ffxsam
Copy link

ffxsam commented May 17, 2024

Interesting. I can't tell what version of lyrics kid3 is using, but see the screenshot below:

CleanShot 2024-05-17 at 12 19 00

And (surprisingly) ffprobe can detect this too:

Input #0, wav, from 'quiet.wav':
  Metadata:
    genre           : Ambient
    creation_time   : 10:54:55
    time_reference  : 283583
    umid            : 0xBB6126C10EAD442384B897E045E2CC3200000000000000000000000000000000
    title           : Test Track
    artist          : Sam Hulick
    album           : Album Name
    track           : 1
    lyrics-eng      : Hello hello!
    date            : 2023

And actually, I do see lyrics in music-metadata's output! Just not where I thought it would be (under a USLT tag in native):

{
  native: {
    'ID3v2.3': [
      { id: 'TIT2', value: 'Test Track' },
      { id: 'TPE1', value: 'Sam Hulick' },
      { id: 'TALB', value: 'Album Name' },
      { id: 'TRCK', value: '1' },
      {
        id: 'USLT',
        value: { language: 'eng', description: '', text: 'Hello hello!' }
      },
      { id: 'TYER', value: '2023' },
      { id: 'TCON', value: 'Ambient' }
    ]
  },

So this really isn't a big issue. It would be nice if it appeared under common for easy access, but it's just a nice-to-have.

@Borewit
Copy link
Owner

Borewit commented May 21, 2024

Seems that an attempt to map USLT had defined, but was never really implemented properly.

'USLT:description': 'lyrics',

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question, clarification, discussion
Projects
None yet
Development

No branches or pull requests

3 participants