How can I print an image on a Bluetooth printer in Android?
问题 I have to print some data on thermal bluetooth printer, I'm doing with this: String message="abcdef any message 12345"; byte[] send; send = message.getBytes(); mService.write(send); It works well for text, but not for images. I think I need to get the byte[] of the image data. I tried getting the data of the image this way: Bitmap bitmap=BitmapFactory.decodeResource(getResources(), R.drawable.qrcode); ByteArrayOutputStream stream=new ByteArrayOutputStream(); bitmap.compress(Bitmap