TianyiShi2001 / audiotags

Unified IO for different types of audio metadata
https://tianyishi2001.github.io/audiotags
MIT License
41 stars 29 forks source link

[Question] Cover Art from .m4a/.mp3 Files #24

Closed bradleat closed 6 months ago

bradleat commented 1 year ago

I am unable to read cover art from m4a and mp3 files. These are just songs that I have purchased from there Apple Music Store (iTunes)

For example:

let tag = Tag::new().read_from_path(p.clone()).unwrap();

let album_cover_mime: String = tag.album_cover().map(|cover| cover.mime_type).unwrap_or(MimeType::Tiff).into();
let picture_data = tag.album_cover().map(|cover| cover.data).unwrap_or_default().to_vec();

The album_cover_mime is set to default, and the picture_data vec is empty.

Am I doing something wrong?

Serial-ATA commented 1 year ago

Do the files have front covers? You can make a test program to check your mp3 files with the id3 crate and check the pictures with Tag::pictures. It could be an issue with the id3 crate.

pinkforest commented 6 months ago

There is no way to replicate this issue - Please re-open if there is data to reproduce this in order to fix it. Thanks