Can you please suggest me the efficient encoding technique to transfer image from iphone/android to server.
base64 encoding is too easy but i’ve heard it is not recommended because it increases the size of original image upto 37%
Should I use base64 encoding,, UTF-8 encoding or read and write streams to send image to server?
i want to use it in image sharing application which is client server app, and client will upload their images to server.
Can you also tell me other possible techniques just for knowledge? and which one to use?
When it comes to phones especially Android streaming will be your best choice.
It’s not matter what format you will choose base64 or UTF-8, eventually a stream will be opened in behind the scene.
The only thing that matters is RAM space consume by your application, if your client will try to encode it by him self before sending it, you will use more memory and some of the devices will run out of memory, this is much more impotent then the time it takes to upload the image to the server or the disc space used by server.
So my advice is: Do not manipulate the image, just stream it as-is, with the most common system tool your client can find.