dhowden / tag

ID3, MP4 and OGG/FLAC metadata parsing in Go
BSD 2-Clause "Simplified" License
558 stars 72 forks source link

[Feature Request] Convert genre byte codes (including "Winamp Extension" codes 80-191) to string values #102

Closed bretttolbert closed 7 months ago

bretttolbert commented 8 months ago

I'm seeing that with some of my mp3 files, .Genre() is returning a byte code in parentheses e.g. "(175)" but for other files it returns the string value "Post-Punk", as expected. E.g.

    - path: /home/pi/Music/Joy Division/Peel Sessions [1986]/08 The Sound Of Music.mp3
      size: 8775680
      format: ID3v2.3
      title: The Sound Of Music
      artist: Joy Division
      album: Peel Sessions
      genre: (175)
      year: 1986
    - path: /home/pi/Music/The Cure/Kiss Me, Kiss Me, Kiss Me [1987]/The Cure - Just Like Heaven.mp3
      size: 5889881
      format: ID3v2.3
      title: Just Like Heaven
      artist: The Cure
      album: Kiss Me, Kiss Me, Kiss Me
      genre: Post-Punk
      year: 1987

Is it possible to make your library always convert these codes to string values per this page? I understand that codes in the range 80-191 are not part of the official ID3 spec but are "Winamp Extension" codes but apparently many of my files have them, unfortunately, and I see that you already support Winamp codes in the 80-147 range.

dhowden commented 7 months ago

Closed due to merge of #103 Thanks @bretttolbert 😄 .