I am a newbie to leaflet.js, and recently, I need to create a CRS in leaflet for coordinate system change. The transformation library I used is proj4leaflet.js. And the problem is when I read the source code in proj4leaflet.js, I see the following code snippet:
L.Proj.CRS = L.Class.extend({
includes: L.CRS,
options: {
transformation: new L.Transformation(1, 0, -1, 0)
// * Represents an affine transformation: a set of coefficients `a`, `b`, `c`, `d`
// * for transforming a point of a form `(x, y)` into `(a*x + b, c*y + d)` and doing
// * the reverse. Used by Leaflet in its projections code.
},
the problem is what is the usage of transform, and why its init definition is L.Transformation(1, 0, -1, 0). I have check the definition of transform function in leaflet.js, and still not understood the reason why it using in this way, any instruction is highly appreciated, thanks a lot.