0

Google requires us to prepare our applications for new scopes storages. So I'm totally modifying my code for that by using SAF. There are a lot of things that I have to deal with but I will start with this question: For a given tree you can easily get a thumbnail for an image file:

Bitmap bitmap = DocumentsContract.getDocumentThumbnail(context.getContentResolver(),treeUri,p,null);

But how to get thumb for a video file and how to get the art album for an audio file?

Is there a way to get the media uri in the form:

content://media/external/images/media/361

from the uri given by SAF?

Thanks.

Aristide13
  • 244
  • 2
  • 16
  • "Is there a way to get the media uri in the form... from the uri given by SAF?" -- try https://developer.android.com/reference/android/provider/MediaStore.html#getMediaUri(android.content.Context,%20android.net.Uri) – CommonsWare Jun 17 '19 at 11:08
  • @CommonsWare Thank you, it seems that I can not use the returned uri with my methods to find the album id and / or the album art ... but this method does not work with the external sd card. If Google wants us to use SAF, would it be better if it is well documented? – Aristide13 Jun 17 '19 at 17:38

0 Answers0