[gdal-dev] flipped

2019-10-31 Thread Dshah
Greetings, When I GDALOpen a .tif image and write a new one, the new image is flipped upside down? could someone please help? const char *pszFilename = "im.tif"; poDataset = (GDALDataset *)GDALOpen(pszFilename, GA_ReadOnly); Best Regards ___ gda

Re: [gdal-dev] Python Bindings and Closed Datasets

2019-10-31 Thread Patrick Young
After some more investigation, I've managed to put together the script below that manifests the issue on my machine (8 core, Ubuntu 19.04, GDAL 2.4.0, Python 3.7). Where I first observed this was in using 8 band WV2 imagery, so that's what the complicated input image is modeled after. Here's an ex

[gdal-dev] gdalsrsinfo Incorrect or Inconsistent results reporting EPSG codes

2019-10-31 Thread David Cakalic
Hi, I've been having a problem using gdal to simply read/report EPSG headers on rasters. I am trying to use it to verify header projection information is correct. First, I am using Windows 10. Rasters are Imagine .IMG format. Command being used is gdalsrsinfo -e {filename} I've tried gdal f

[gdal-dev] NetCDF and ESA Probav issue with corner coordimates

2019-10-31 Thread Ivan Lucena
Hi Folks, I Downloaded NetCDF files from http://land.copernicus.eu/global/products/ndvi and I am having problems with the GeoTransform that the driver is getting. The image extents, as you can see in following gdalinfo report, goes beyond the -180 and +180 longitude degrees (half resolution, h

Re: [gdal-dev] Confusion on intersection

2019-10-31 Thread jratike80
Hi, This question does not have much to do with just GDAL but it would have been a perfect one to be asked from https://gis.stackexchange.com. Intersects is a function that tells if two geometries intersect and answer is true or false. Intersection computes the intersection of the two geometries.

Re: [gdal-dev] Question on gdal_contour and limiting the range of contours generated.

2019-10-31 Thread Stephen Woodbridge
Thanks I have not seen the raster common option file thing. I’ll look at it. Sent from my iPhone > On Oct 31, 2019, at 2:11 PM, jratike80 > wrote: > > Hi, > > One more suggestion, have you tried the -fl option "Name one or more “fixed > levels” to extract"? Requires some writing but only o

[gdal-dev] Confusion on intersection

2019-10-31 Thread Ahmet Temiz
Hi, Please correct me if I am wrong. I want to get intersected part of a line that overlays a polygon. do I need to use firstly intersects , then intersection? Intersection part is like: line->intersection (polygon). // that returns linestring??? Is it correct ? Regards -- Ahmet Temiz Jeoloji M

Re: [gdal-dev] Question on gdal_contour and limiting the range of contours generated.

2019-10-31 Thread jratike80
Hi, One more suggestion, have you tried the -fl option "Name one or more “fixed levels” to extract"? Requires some writing but only once if you save the list into an optfile https://gdal.org/programs/raster_common_options.html. I haven't tried the option with hundreds of fixed levels, though. -J

Re: [gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread Mateusz Loskot
+1 Thanks Even! Mateusz On Thu, 31 Oct 2019 at 17:46, Howard Butler wrote: > > +1 > > Howard > > On Oct 31, 2019, at 9:39 AM, Daniel Morissette > wrote: > > +1 > > Daniel > > On 2019-10-31 07:08, Even Rouault wrote: > > Hi, > A few issues [1] have been fixed since in those branches since the

Re: [gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread Howard Butler
+1 Howard > On Oct 31, 2019, at 9:39 AM, Daniel Morissette > wrote: > > +1 > > Daniel > > On 2019-10-31 07:08, Even Rouault wrote: >> Hi, >> A few issues [1] have been fixed since in those branches since the RCs, but >> they predated 2.4.0, so those new releases are not worse than their pre

Re: [gdal-dev] Question on gdal_contour and limiting the range of contours generated.

2019-10-31 Thread Stephen Woodbridge
Jukka, Thanks! After trying shapefile and exceeding 2GB, I switched to postgres and deleted the elevation as you suggested. I'm working with a global relief model the includes both elevation and bathymetry depth over the whole world at about 15 arc-sec/pixel. I generates a lot of contour lin

Re: [gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread Daniel Morissette
+1 Daniel On 2019-10-31 07:08, Even Rouault wrote: Hi, A few issues [1] have been fixed since in those branches since the RCs, but they predated 2.4.0, so those new releases are not worse than their previous x.y.0, so I move to Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final +1 Eve

Re: [gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread Sean Gillies
Even, I've built 3.0.2rc1 and didn't find any new issues. +1 On Thu, Oct 31, 2019 at 5:09 AM Even Rouault wrote: > Hi, > > A few issues [1] have been fixed since in those branches since the RCs, > but > they predated 2.4.0, so those new releases are not worse than their > previous > x.y.0, so I

Re: [gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread jratike80
+1 -Jukka Rahkonen- Even Rouault-2 wrote > Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final -- Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mail

[gdal-dev] Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final

2019-10-31 Thread Even Rouault
Hi, A few issues [1] have been fixed since in those branches since the RCs, but they predated 2.4.0, so those new releases are not worse than their previous x.y.0, so I move to Motion: approve GDAL 2.4.3RC1 and 3.0.2RC1 as final +1 Even [1] - PDS: fix opening of datasets with BSQ organ

Re: [gdal-dev] Fwd: Gdal - multipolygon - geometry errors instead holes

2019-10-31 Thread Even Rouault
On mardi 29 octobre 2019 03:31:10 CET jratike80 wrote: > Hi, > > Your case is a bit hard to analyze with end users tools, probably low level > study about how the shapefile driver or GEOS works is needed. > > The problematic geometry is a rather big multipolygon and it can be found > with ogrinfo

Re: [gdal-dev] Question on gdal_contour and limiting the range of contours generated.

2019-10-31 Thread jratike80
Second thought, perhaps I would just delete unnecessary contour lines afterwards instead of flattening the DEM. gdal_contour -f gpkg -a elev -off -121.92 -i 1.524 bathy-value/crm_vol2.nc.tif bathy-contours/crm_vol2.nc-5.gpkg ogrinfo -sql "delete from crm_vol2.nc-5 where elev>0" bathy-contours/crm

Re: [gdal-dev] Fwd: Gdal - multipolygon - geometry errors instead holes

2019-10-31 Thread jratike80
Hi, It seems to me that the geometry is valid but for some reason the shapefile reader reads it wrong. It is not trivial to investigate the issue and developers tend to be busy. Meanwhile you can ask that ArcMap user to save data into GeoPackage so you can make a test with that. -Jukka Rahkonen-

Re: [gdal-dev] Question on gdal_contour and limiting the range of contours generated.

2019-10-31 Thread jratike80
Hi, I believe I would use gdal_calc https://gdal.org/programs/gdal_calc.html and make the terrain above the sea level flat before creating the contours. And I would avoid shapefiles and use GeoPackage as output format. There is a button "Edit on GitHub" in the top-right corner on page https://gd

Re: [gdal-dev] Fwd: Gdal - multipolygon - geometry errors instead holes

2019-10-31 Thread Pepa Beneš
Hi Tobias, please, could You help me, with originall question? Is the geometry valid or it isn't? If it is not, why? How to explain it to the data author, who can only see valid geometry with holes where he wants to see them in his ArcMap. But QGIS can see "nested shells" there and it is consisten