Hot answers tagged

3

You could just coerce the extent into a SpatialPolygons object and then use "spTransfrom". library(sp) ( e <- raster::extent(-5559753, -4447753, -4447852, -3335852) ) e <- as(e, "SpatialPolygons") sp::proj4string(e) <- "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +a=6371007.181 +b=6371007.181 +units=m +no_defs" e.geo <- sp::...


2

That is a trivial task with gdal: ogr2ogr -t_srs EPSG:3857 f.shp new.shp See http://www.gdal.org/ogr2ogr.html for more information. There might be ruby bindings for this, I have no idea. EPSG:3857 coordinates are not lat/long though, if you really need those, just use EPSG:4326.


1

You might run into a problem with the antipodal point of the projection. If you clip your raster to the area of validity (that is Europe), it works: gdal_translate -projwin -26 75 44 28 -of GTiff bluemarble.tif bluemarble-Europe.tif gdalwarp -overwrite -s_srs EPSG:4326 -t_srs EPSG:3035 -of GTiff bluemarble-Europe.tif bluemarble-3035.tif You might take ...


1

It's been a few months since I posted this. @michael-miles-stimson suggested that the correct way to do this would be to sample points along each edge of the bounding box, project them, then build an encompassing bounding box on those points. The drop-in Python/GDAL code below does this and allows you to select the number of interpolating points you'd like ...


1

Project tool has Vertical parameter since 10.4. The link also mentions that you need to install additional package with coordinate system data.



Only top voted, non community-wiki answers of a minimum length are eligible