bill %!s(int64=4) %!d(string=hai) anos
pai
achega
6321b84c71
Modificáronse 1 ficheiros con 4 adicións e 2 borrados
  1. 4 2
      locat/components/image-transform/index.js

+ 4 - 2
locat/components/image-transform/index.js

@@ -195,6 +195,7 @@
     const canvas = document.createElement('canvas');
     const imageCanvas = new ol.source.ImageCanvas({
       canvasFunction(extent, scale, _2, size) {
+        console.log('-------------')
         const pos = itudeToCanvasPos(map, extent, itude)
         const imgData = { width: 0, height: 0 }
         args.img.forEach(imgs => {
@@ -205,8 +206,9 @@
             imgData.height = height
           }
         })
-        pos.x -= imgData.width / 2 * scale
-        pos.y -= imgData.height / 2 * scale
+        console.log(scale)
+        // pos.x -= imgData.width / 2 * scale
+        // pos.y -= imgData.height / 2 * scale
         canvas.width = size[0];
         canvas.height = size[1]
         canvas.posToReal = genImgCanvasPosToReal(map, canvas);