Android Question How to convert bitmap to byte[] ?

fash866

Member
Licensed User
Hi!
I used LoadBitmapSample to comprees a photo,and want to upload the compressed photo to http server , but httpUtils2 only support post bytes,is there any way to convert bitmap to byte[]?

Or, is ther other way to compress a photo and upload it ?
 

Ganiadi

Member
Licensed User
Can anybody help,

Im trying to get image file from tab and send it to the desktop server written using vb6.

What im doing is convert the image to byte array and send it using socket stream
astream.Write(data)

Problem:
My desktop server received the data correctly, but when i open the image file is corrupted.
It seems the structure is incorrect.


Tks
 
Top