[Android] [PATCH] Download cover art also from http urls
Marc K.
morckx at gmail.com
Tue Jun 13 14:06:57 CEST 2017
On Tue, 2017-06-13 at 09:57 +0000, Geoffrey Métais wrote:
> Hm okay good point.
> I can merge it then and remove the call in AsyncImageLoader.
>
Great, but please be aware that readCoverBitmap can run on the main
thread, so that https://patches.videolan.org/patch/16915/ will be
needed too for the improbable but absolutely possible case that someone
is quick enough to hit play before the media icon is loaded from the
worker thread of network browser.
An alternative would be to use getBitmapFromIconCache in
readCoverBitmap and keep AsyncImageLoader as it is. Then the thread
check in downloadBitmap would not be necessary. However I like my
variant more, because it is a sensible fallback to just consider the
cache if network cannot be used. There might also be even better
variants.
> Le mar. 13 juin 2017 à 11:02, Marc K. <morckx at gmail.com> a écrit :
> > On Tue, 2017-06-13 at 08:12 +0000, Geoffrey Métais wrote:
> > > Http cover arts are already downloaded, call is here: https://cod
> > e.vi
> > > deolan.org/videolan/vlc-android/blob/master/vlc-
> > >
> > android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java#L141
> > > Right before the AudioUtil call actually.
> > >
> > Sorry, my commit message was slightly imprecise. Without this
> > patch,
> > cover art for network media is indeed shown in the browser, but
> > missing
> > in the player, the notification, the info activity, and on the lock
> > screen.
> >
> > _______________________________________________
> > Android mailing list
> > Android at videolan.org
> > https://mailman.videolan.org/listinfo/android
> >
>
> _______________________________________________
> Android mailing list
> Android at videolan.org
> https://mailman.videolan.org/listinfo/android
More information about the Android
mailing list