I have problems converting a input stream from web into bitmap. Problem occurs only when input image type is .BMP (bitmap). In that case: bitmapFactory.decodeStream
Here is a one-line answer
val bitmap = BitmapFactory.decodeStream(inputStream)
Returns a Bitmap
Bitmap