androidx / androidx/media

Helpers and demos for working with MediaStore song lists

Open
#1,934 0 comments 0 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

enhancement low priority
Dominant language
Java
Stars
3k
Forks
955
Avg merge
12d 14h
Merged PRs (30d)
2

Description

Despite the project being named "media", there are no APIs or helpers to work with MediaStore. I believe a helper to execute MediaStore.Media.Audio queries that returns a list of MediaItems (automatic conversion from cursor fields to MediaItem) would deduplicate a lot of code people have to write over and over again, and there is basically no reason this piece of code cannot be shared across all apps.
I am also interested in a demo showcasing how to handle playback resumption with MediaStore, as MediaStore sometimes needs some time to load and rescan storage and SD card after boot and media IDs won't resolve fast enough to be used in onPlaybackResumption(). I currently serialize the entire MediaItem playlist to disk, but I am curious if there is a better solution.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.