Fix alpha compositing using gl.BLEND

Also, reformat code using webstorm.