ImageArcGIS Layer misaligned
See original GitHub issueHi Folks,
I’m building a Webapp where I need to project a ImageArcGIS Layer on top of a regular map. Until today, I’m not able to reproduce this bug on my machine (Macbook Air 13" 2015). The displayed ImageArcGIS Layer is being projected nowhere near it should be. At first, I thought the bug exists only on Chromium-based browsers, but recently I got notices that it also happens on Firefox.
This is on Firefox
This is on Chrome
Weirdly, when used with Chromium installed on the same machine, the ArcGIS layer is projected as it should be, like this (Mozilla Firefox on my Machine):
My code to instantiate the ImageArcGIS Layer:
overlayLayer = new ImageLayer({ source: new ImageArcGISRest({ url: layer.URL, params: layer.Parameters, crossOrigin: "anonymous" }), opacity: layer.Opacity, visible: true })
It happens to all my inserted ArcGIS Layer, regardless of the service URL.
Steps to reproduce the behavior:
Until today I couldn’t reproduce it. Either it’s there, or not.
Expected behavior The ArcGIS layer should be where it’s supposed to be projected.
Thanks in advance,
Tomás
Issue Analytics
- State:
- Created 4 years ago
- Comments:9 (2 by maintainers)
I noticed the same problem with ol v6.3.1 on Firefox 76.0.1. For me it happens on a VectorLayer, so it does not seem to be specific to ArcGIS layers.
When I check the element with devtools, the canvas element for the layer has its style set to:
"position: absolute; left: 0px; transform-origin: left top 0px; transform: matrix(0.8, 0, 0, 0.8, 0, 0);"
The transform matrix scales the layer down to 80% which causes the layer to be misaligned with the basemap.
Does not happen on Chrome 81.0.4044.
i got this problom too. if i use chrome devtool , toggle device toolbar and set the resolution to 3784*1400, the img is not in the right position!