Create new BITS_PER_PIXEL_CHANNEL constant
Improve handling of WebGL init problems
Move code to new init() method