I noticed that Google’s new page preview gets it’s images using base64 rather than plain e.g. jpgs or png’s
What are the advantages of doing this?
Can base64 encoded images be compressed better during transit?
Or perhaps cached better by the browser or caching proxy?
Is it so they can do one HTTP request and receive the image and information about the image in one hit?
Any other ideas?
[EDIT]
I’ve just had a thought, maybe it’s so google can use their new image format
http://code.google.com/speed/webp/ without support from browsers?
However looking at the string returned (using the fiddler to intercept the http traffic), the string mentions “image/jpeg”. Unless some images are returned in webp format.
The image is a data URL that’s received from the server as a JSON(-ish) package with some metadata. I presume that packaging both the image data and the metadata into a single request is worth it in terms of caching and performance.