If you have the image URL you can open the resource it represent using the stream(abstraction):
new URL("your.image.url.com").openStream()
. This method call will return an object of type InputStream
which you can pass as an argument to setStream()
method.
If you dont want to specify a stream directly, you can open the remote stream, create a Bitmap and then either use a WallpaperManager instance or do a context.setWallpaper(bitmap)
(this is deprecated) to set your bitmap as the wallpaper.
For reference take a look at this thread.