You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working on a music player that can show the basic metadata of the current song and its cover art. Also, if no metadata is available, it can be downloaded from the internet and saved into the file. To achieve this I'm using the following code:
SongMetadata = TagLib.File.Create(path);
SongMetadata.Tag.Title = SongName;
TagLib.Picture CoverArt = new Picture
{
Type = PictureType.FrontCover,
Description = "Cover art",
MimeType = System.Net.Mime.MediaTypeNames.Image.Jpeg,
Data = ImageBytes
};
SongMetadata.Tag.Pictures = new IPicture[] { CoverArt };
It works pretty well for MP3 files, but today I tested it with M4A files and they corrupted. I've been searching for a solution, but I didn't get anything yet. I've been reading about M4A and I know it can't contain ID3 tags, which MP3 uses. I need help please D:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'm working on a music player that can show the basic metadata of the current song and its cover art. Also, if no metadata is available, it can be downloaded from the internet and saved into the file. To achieve this I'm using the following code:
SongMetadata = TagLib.File.Create(path);
SongMetadata.Tag.Title = SongName;
TagLib.Picture CoverArt = new Picture
{
Type = PictureType.FrontCover,
Description = "Cover art",
MimeType = System.Net.Mime.MediaTypeNames.Image.Jpeg,
Data = ImageBytes
};
SongMetadata.Tag.Pictures = new IPicture[] { CoverArt };
It works pretty well for MP3 files, but today I tested it with M4A files and they corrupted. I've been searching for a solution, but I didn't get anything yet. I've been reading about M4A and I know it can't contain ID3 tags, which MP3 uses. I need help please D:
Beta Was this translation helpful? Give feedback.
All reactions