fixed an issue where setPixelRatio changed canvas to wrong size
Merge pull request #786 from kzhdev/fix-setPixelRatio

fixed an issue where setPixelRatio changed canvas to wrong size