0

I'm using a GoogleApiClient MessageApi method which accepts an arbitrary payload specified as a byte array.

For my payload I have some strings and a Bitmap that I want to transfer all together in one go.

What options are there available for packaging the strings and bitmaps and converting to a byte array?

Gruntcakes
  • 37,135
  • 41
  • 177
  • 359

1 Answers1

0

A Bitmap can be converted to bytes through copyPixelsToBuffer. A string has getBytes.

JHH
  • 7,508
  • 7
  • 40
  • 74