I have a web application that allows a client to request several image thumbnails at once. The response is currently sent as a JSON-encoded list of objects where each object includes the (encoded) image data. (I'm using JSON.NET; it looks like it's encoding the image data as base64 strings).
If I change my application such that the image data is sent separately from the JSON object, as "binary" (application/octet-stream) content, will this be more efficient?
Or put more simply, is application/octet stream a more compact encoding than base64?
Also, how does this differ from image/jpeg?
OK, so application/octet-stream is essentially binary, which is - of course - more efficient than base64. Something like 30% more efficient in terms of space, and removes the need to encode/decode.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With