@@ -189,15 +189,15 @@ public function __construct(LatLng $centerMap, int $zoom, XY $outputSize)
189189 );
190190 $ this ->latLngTopRight = new LatLng (
191191 static ::tilePxToLat ($ this ->mapCropTopLeft ->getY (), $ this ->tileTopLeft ->getY (), $ zoom ),
192- static ::tilePxToLng ($ this ->mapCropBottomRight ->getX (), $ this ->tileBottomRight ->getX (), $ zoom )
192+ static ::tilePxToLng (256 - $ this ->mapCropBottomRight ->getX (), $ this ->tileBottomRight ->getX (), $ zoom )
193193 );
194194 $ this ->latLngBottomLeft = new LatLng (
195- static ::tilePxToLat ($ this ->mapCropBottomRight ->getY (), $ this ->tileBottomRight ->getY (), $ zoom ),
195+ static ::tilePxToLat (256 - $ this ->mapCropBottomRight ->getY (), $ this ->tileBottomRight ->getY (), $ zoom ),
196196 static ::tilePxToLng ($ this ->mapCropTopLeft ->getX (), $ this ->tileTopLeft ->getX (), $ zoom )
197197 );
198198 $ this ->latLngBottomRight = new LatLng (
199- static ::tilePxToLat ($ this ->mapCropBottomRight ->getY (), $ this ->tileBottomRight ->getY (), $ zoom ),
200- static ::tilePxToLng ($ this ->mapCropBottomRight ->getX (), $ this ->tileBottomRight ->getX (), $ zoom )
199+ static ::tilePxToLat (256 - $ this ->mapCropBottomRight ->getY (), $ this ->tileBottomRight ->getY (), $ zoom ),
200+ static ::tilePxToLng (256 - $ this ->mapCropBottomRight ->getX (), $ this ->tileBottomRight ->getX (), $ zoom )
201201 );
202202 }
203203
0 commit comments