Вот как я справляюсь с этим в моем приложении:
// bitmap is your Bitmap object
ByteArrayOutputStream stream = new ByteArrayOutputStream();
// The next line should be adjust to use the format and compression you want.
bitmap.compress(CompressFormat.PNG, 0, stream);
byte[] byteArr = stream.toByteArray();
// The next line would be where you write the byte array to your xml structure:
myXml += Base64.encodeBase64String( byteArr );
В моем приложении байт [] сохраняется в БД в виде большого двоичного объекта до создания структуры xml. Так что этот код не совсем то, что я делаю. Но это должно дать вам идею.