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.