The following line of code will turn off saving ID3v2 numeric genres for your entire application.
TagLib.Id3v2.Tag.UseNumericGenres = false;
Question
I'm on VB.NET 2012 Express, using the mono/taglib-sharp 2.0 library (Win7).
If I run this working code snippet to save 3 genres into the id3v2 tag of an existing mp3 track:
Dim ThreeGenresInStringArray() As String = {"Folk rock", "Bluegrass", "Indie folk"}
Dim MyTaglibMP3 As TagLib.File = TagLib.File.Create("C:\temp\I'm Alive.mp3")
MyTaglibMP3.Tag.Genres = ThreeGenresInStringArray
MyTaglibMP3.Save()
MyTaglibMP3.Dispose()
the second genre will be converted from the string 'Bluegrass' to the integer 89. If I look into this id3tag with a tool like Mp3tag, the genre will be shown as 'Folk rock/89/Indie folk'.
How can I stop taglib-sharp to convert "known" genres into numbers?
Solution
The following line of code will turn off saving ID3v2 numeric genres for your entire application.
TagLib.Id3v2.Tag.UseNumericGenres = false;