Introducing the ‘mozjpeg’ Project
Bravo. I love JPEG. Amazing that it's been 23 years since its release and it remains as useful as ever.<p>I remember what it was like to watch a 320*200 JPEG image slowly build up on a 386SX PC with a VGA card. Today, a HD frame compressed with JPEG can be decoded in milliseconds. This highlights the secret to JPEG's success: it was designed with enough foresight and a sufficiently well-bounded scope that it keeps hitting a sweet spot between computing power and bandwidth.<p>Did you know that most browsers support JPEG video streaming using a plain old <img> tag? It works also on iOS and Android, but not IE unfortunately.<p>It's triggered by the "multipart/x-mixed-replace" content type header [0]. The HTTP server leaves the connection open after sending the first image, and then simply writes new images as they come in like it were a multipart file download. A compliant browser will update the image element's contents in place.<p>[0] <a href="http://en.wikipedia.org/wiki/MIME#Mixed-Replace" rel="nofollow">http://en.wikipedia.org/wiki/MIME#Mixed-Replace</a>