[gdal-dev] Possible bug in GDAL 2.1 RC4 with MBTiles creation

2016-04-30 Thread Gunnar Blom
Hi,   I've found a possible bug in GDAL 2.1 RC4 and the MBTiles driver.   I have the following image that I'm geo referencing: http://imgbox.com/tLFn3Auq   If I'm using the follwing code to warp the image based on a GeoTransform, it works well: https://gist.github.com/gunnarblom/9d73aa4358f3d

[gdal-dev] Questions about MBTiles write support @ GDAL 2.1 RC4

2016-04-30 Thread Gunnar Blom
Hi.   Awesome work with GDAL 2.1 RC4 and the MBTiles write support. I've ran into some questions using this feature with the C/C++ API.   1) When creating a MBTiles file, only one layer is written. Can you use GDAL to populate other layers? 2) Can you choose to create 512*512px tiles instead

Re: [gdal-dev] IReadBlock fails on alpha band, GDAL 2

2016-04-30 Thread Matt Perry
Even, Thanks for the fix, the workaround and the detailed explanation. I knew there must be a reason for the strange threshold. >> hBand = GDALGetRasterBand( hDataset, 4 ); >> pafScanline = (int *) CPLMalloc(sizeof(int) * 734 * 734); >> GDALRasterIO( hBand, GF_Read, 0, 0, 1223, 1223,

Re: [gdal-dev] compile error on windows

2016-04-30 Thread Jeff McKenna
On 2016-04-29 5:17 PM, Ryan Grout wrote: Hello, I'm attempting to build GDAL for windows using Visual Studio 2008. I've included the output of the build failure below. I don't see anything wrong with the linking command (hdf5 library is there). I've double checked the exported symbols of hdf5.

Re: [gdal-dev] IReadBlock fails on alpha band, GDAL 2

2016-04-30 Thread Even Rouault
Hi Matt, > I'm seeing some errors reading reduced-resolution buffers from the > alpha band of an RGBA image. > > Code and link to raster to reproduce: > https://gist.github.com/perrygeo/07ce04fe886d1c8090ab1b22d7579396 > > > The original raster is 4 bands, 1223x1223. If I attempt to read a > 73

Re: [gdal-dev] GDAL 2.0.2 & gpkg woes

2016-04-30 Thread Even Rouault
On Friday 29 April 2016 14:07:52 Alan Stewart wrote: > My debug build of ogr2ogr.exe fails in exactly the same way as my > application code fails. Apparently there's some difference in how the new > GPKG code uses spatialite or expects spatialite to be built? The same > libspatialite DLL works with

Re: [gdal-dev] OGR_L_SetAttributeFilter

2016-04-30 Thread Even Rouault
Hi Paul, The reference for OGR SQL is http://gdal.org/ogr_sql.html (I'm not sure how relevant this ogdi page is) "fid" is indeed a special field in OGR SQL. I'm not sure if it is really specified how that is supposed to work when a layer has a regular field also called "fid". From a quick test

Re: [gdal-dev] Layer intersection: two polygons with a common point

2016-04-30 Thread Ari Jolma
28.04.2016, 10:56, Even Rouault kirjoitti: Oh I see we are both involved in this ;-) The advantage of the current behaviour is that it is compatible with most popular output formats that don't like mixing geometry types in the same layer (think of shapefiles, and generally postgis, spatialite whe