The ZXing library's Writer.encode()
function returns a BitMatrix
object. How does one convert that to a standard java Bitmap
object so it can be used as the source of an ImageView
in Android?
writeToFile(BitMatrix matrix, String format, File file)
thsi method will write the BitMatrix into a file, now you can decode this file using
BitmapFactory.decodeFile(newly created file name with path)
This will return a Bitmap
For more detail see this link