Extract album cover from mp3 file in android

前端 未结 4 1497
执笔经年
执笔经年 2020-12-14 04:59

Hello Everyone , In my media player i need to display the album cover(i dont know how it pronounced actually..I hope right) of the song. I knew for that i have to e

4条回答
  •  一个人的身影
    2020-12-14 05:15

     MediaMetadataRetriever mmr = new MediaMetadataRetriever();
     mmr.setDataSource(filePath);
    
    String albumName = mmr.extractMetadata(MediaMetadataRetriever.METADATA_KEY_ALBUM));
    

    Note this will work only at api level 10 or above

提交回复
热议问题