Skip to content

Commit

Permalink
Adding notes about the crossOriginKeyword tile option for Layer.OSM a…
Browse files Browse the repository at this point in the history
…nd Layer.Bing.
  • Loading branch information
ahocevar committed Feb 11, 2012
1 parent c6312b6 commit ca2c352
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion notes/2.12.md
Expand Up @@ -76,10 +76,14 @@ The base `OpenLayers.Geometry` class no longer depends on `OpenLayers.Format.WKT

Without the WKT format included (by default), the `OpenLayers.Geometry::toString` method now returns "[object Object]." Previously, it returned the Well-Known Text representation of the geometry. To maintain the previous behavior, include the OpenLayers/Format/WKT.js file in your build.

## OSM Layer
## OSM and Bing Layers

`Layer.OSM` is now defined in its own script file, namely `OpenLayers/Layer/OSM.js`. So people using `Layer.OSM` should now include `OpenLayers/Layer/OSM.js`, as opposed to `OpenLayers/Layer/XYZ.js`, in their OpenLayers builds. (See https://github.com/openlayers/openlayers/issues/138)

The `OpenLayers.Tile.Image` class now has a method to get a canvas context for processing tiles. Since both OSM and Bing set Access-Control-Allow-Origin headers for their tiles, it is possible to manipulate a canvas that these tiles were rendered to even if the tiles come from a remote origin. Especially when working with custom OSM tilesets from servers that do not send Access-Control-Allow-Origin headers, it is now necessary to configure the layer with

tileOptions: {crossOriginKeyword: null}

## Projection & SphericalMercator

In previous releases, coordinate transforms between EPSG:4326 and EPSG:900913 were defined in the SphericalMercator.js script. In 2.12, these default transforms are included in the Projection.js script. The Projection.js script is included as a dependency in builds with any layer types, so no special build configuration is necessary to get the web mercator transforms.
Expand Down

0 comments on commit ca2c352

Please sign in to comment.