Add tilePixelRatio option to ol.source.XYZ

This PR supersedes #2308. It squashes @klokan's commits into a single commit, and uses the `ol.proj.transformExtent` as suggested in a comment in #2308.

I'll merge this before gamma.2.