gberaudo / olwind

Wind layers for OpenLayers
Other
34 stars 10 forks source link

This is a good project, but I can't find map.getRenderer() in ol6, so how can i use other API instead this function? #6

Closed lzio closed 3 years ago

lzio commented 3 years ago

THX

gberaudo commented 3 years ago

Indeed @lzio, this project was indeed done for OL5. For OL6 I think you should create a new layer type like done in this project: https://github.com/geoblocks/mapboxlayer/blob/master/src/MapBoxLayer.js

See also https://github.com/geoblocks/mapboxlayer-legacy/blob/master/examples/demo.js and https://github.com/geoblocks/mapboxlayer-legacy/blob/master/src/MapBoxLayer.js for the corresponding legacy OL5 code.

lzio commented 3 years ago

Indeed @lzio, this project was indeed done for OL5. For OL6 I think you should create a new layer type like done in this project: https://github.com/geoblocks/mapboxlayer/blob/master/src/MapBoxLayer.js

See also https://github.com/geoblocks/mapboxlayer-legacy/blob/master/examples/demo.js and https://github.com/geoblocks/mapboxlayer-legacy/blob/master/src/MapBoxLayer.js for the corresponding legacy OL5 code.

Thank you for you reply, it's exactly what i want