-
Notifications
You must be signed in to change notification settings - Fork 306
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setArtworkUri could accept file:// and content:// Uris #271
Comments
Thanks! We recently added DataSourceBitmapLoader that is able to download from For proper integration we should:
|
For sharing with other apps you probably need to use a |
Thank you. I will try out |
Use case description
I develop and maintain an audio app that stores the covers for its media as files locally (in external storage). I want to use those local files as the artwork in a
MediaItem
.Proposed solution
setArtworkUri
inMediaMetadata.Builder
could acceptUri
s with the schemefile://
andcontent://
Alternatives considered
(1) I can convert the local cover file into a
ByteArray
and pass that tosetArtworkData
. But that solution uses more memory compared to just setting that artwork Uri.(2)
setArtworkUri
somewhat works withfile://
-Uris ... in the sense that the correct cover is displayed in the app'sNotification
. ButMediaDataManager
throws aFileNotFoundException
(Permission denied). So I guess other clients of my app will not be able to see the cover.The text was updated successfully, but these errors were encountered: