开发者

Overhead of creating a base 64 string from an image?

Im writing a base 64 string that i have made from an image to a text file and I'm getting files that are between 2-4 MBs and around 50,000 lines long is this normal a normal size?

I'm doing the programming in Java and have not worked wit开发者_高级运维h base 64 or image handling in this way before and just wanted to check if there was a way to make the file size smaller?

Any help with this would be greatly appreciated, Thank you.


Base64 introduces content expansion, at an approximate rate of 4:3 (that's a 33% increase in size). So assuming the size of your image files is approximately 75% of the size of your base64 text files, I'd say yes, that's normal.

There isn't any good way to reduce the size without compressing them, which would likely introduce binary bytes, making the base64 encoding pointless in the first place.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜