Wizcorp/Ejecta-X — pull request #39 by jrouault (2014-02-24 09:47:18+00:00)
Title: Fix to use premultiplied alpha and change the blending mode accordingly.

PNG files and ```globalCompositeOperation``` 'lighter' is already tested in the current test code.

Here is a piece of code to add in the save/restore part, at the end of the animate function, to check if the alpha is correctly premultiplied and if the blending is correct with the draw order:
```
if (img) {
ctx.fillStyle = '#fff';
ctx.fillRect(0, 200, 100, 300);
ctx.drawImage(img, 10, 200);
ctx.drawImage(img, 10, 220);
ctx.drawImage(img, 30, 220);
}
```
To try if it didn't broke anything with JPG files, Dunecat can be used (http://gooby.naurunappula.com/org/ed/11/ed1105d96c39f13f/0/132914.jpg).