Fix incorrect image position when optimizations used
Fix bug with shared matrices

Store copy of object instead of pointer to the original one, to be able to use the same matrix object is (but with different values) in several beginBitmapFill() calls.
Merge pull request #379 from restorer/master

Fix for beginBitmapFill and drawRect for html5 target