Dhruv Gairola[^] wrote:Try this: Java // convert from bitmap to byte array public byte[] getBytesFromBitmap(Bitmap bitmap) { ByteArrayOutputStream stream = new ByteArrayOutputStream(); bitmap.compress(CompressFormat.JPEG, 70, stream); return stream.toByteArray(); }
// convert from bitmap to byte array public byte[] getBytesFromBitmap(Bitmap bitmap) { ByteArrayOutputStream stream = new ByteArrayOutputStream(); bitmap.compress(CompressFormat.JPEG, 70, stream); return stream.toByteArray(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)