[gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Tamas Szekeres
Hi All, We're thinking about implementing a new OGR driver which would represent a set of images as a vector data source. The images are taken from any GPS compatible mobile device, and each picture would be represented as a point feature, the positions would be extracted from the exif information

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Andreas Neumann
Hi Tamas, That would be interesting. So the user could specify a folder with images and GDAL would create an OGR layer that would expose the photo location? The OGR feature would have certain EXIF data exposed as attributes? If you work on this, could you also expose other EXIF data, such as

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Even Rouault
Le lundi 23 juillet 2012 09:51:14, Tamas Szekeres a écrit : > Hi All, > > We're thinking about implementing a new OGR driver which would represent a > set of images as a vector data source. The images are taken from any GPS > compatible mobile device, and each picture would be represented as a poi

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Tamas Szekeres
Hi Andreas, Yes I wanted to expose further information, too. It could probably be user configurable. The driver would be read only, the EXIF would be extracted by using the corresponding GDAL drivers. The site you refer to is very interesting,. This is something that we'd like to achieve. It is al

[gdal-dev] Ogr: Difference betwen SQLexectue() and SetAttributFilter() ?

2012-07-23 Thread Benjamin
Hi, There is a difference betwen : layer = ds.ExecuteSQL("SELECT * FROM MY_TABLE WHERE ID='my_id'", null, ""); And layer = ds.GetLayerByName("MY_TABLE"); layer.SetAttributeFilter("ID='my_id'"); ? When you fetch your feature with layer.getNextFeature(), there are numerous request with the 2nd

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Tamas Szekeres
Hi Even, I just want to use the directory name to define the connection to the images, we could also provide to scan the files in subdirectories if needed. I would prefer to have a new driver not just an offline tool for creating OGR datasets, in this case many existing applications (like MapServe

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Even Rouault
Le lundi 23 juillet 2012 11:27:01, Tamas Szekeres a écrit : > Hi Even, > > I just want to use the directory name to define the connection to the > images, we could also provide to scan the files in subdirectories if > needed. Do you imagine something like : ogrinfo my_directory_with_images or

Re: [gdal-dev] Ogr: Difference betwen SQLexectue() and SetAttributFilter() ?

2012-07-23 Thread Even Rouault
Le lundi 23 juillet 2012 11:19:48, Benjamin a écrit : > Hi, > > There is a difference betwen : > > layer = ds.ExecuteSQL("SELECT * FROM MY_TABLE WHERE ID='my_id'", null, ""); > > And > > layer = ds.GetLayerByName("MY_TABLE"); > layer.SetAttributeFilter("ID='my_id'"); > > ? Short answer: Gene

Re: [gdal-dev] New OGR driver to read OpenStreetMap .osm / .pbf files

2012-07-23 Thread Even Rouault
Le lundi 23 juillet 2012 00:09:05, Jukka Rahkonen a écrit : > Even Rouault mines-paris.org> writes: > > > > However, select with SQL feels sub-optimal. > > > > > > Yes, when you use ogr2ogr with explicit layer names, there are > > > optimizations. For example, when you only specify the layer 'poi

[gdal-dev] Oracle support available by default in any OSGeo software

2012-07-23 Thread Nicolas Simon
Hi , I't very frustrating, each time I would like to use OSGeo software (GDAL/OGR, QGIS, ...) they don't support oracle database. Every time, everything should be recompiled from source with oracle support enabled. A long and not easy process... The reason usually evoked for t

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread taibc
chaitanya_ch wrote > > Tai, > > GDAL needs GEOS to perform these geometry functions. Make sure you install > that. > > On Sat, Jul 21, 2012 at 12:19 PM, taibc wrote: > > Hi Chaitanya, I installed GEOS succesfful, and copy file geos.dll into my project. But I still got the e

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread Mateusz Loskot
On 23 July 2012 11:52, taibc wrote: > I installed GEOS succesfful, and copy file geos.dll into my project. But I > still got the error: "GEOS support not enable" when using the method > "Within" > > Are there something wrongs ? You need to edit nmake.opt and rebuild GDAL. Check this thread: http:

[gdal-dev] OSM Driver and World Planet file (pbf format)

2012-07-23 Thread Smith, Michael ERDC-RDE-CRREL-NH
I'm finding that the new OSM Driver (I tested again with r24699) has a problem when working with the whole planet file. When I tried with the US Northeast subset, I got multipolygons and multilinestring entries. When reading the whole planet file, I did not. It gets to 70% and then ends (but wit

Re: [gdal-dev] OSM Driver and World Planet file (pbf format)

2012-07-23 Thread Even Rouault
Le lundi 23 juillet 2012 12:56:12, Smith, Michael ERDC-RDE-CRREL-NH a écrit : > I'm finding that the new OSM Driver (I tested again with r24699) has a > problem when working with the whole planet file. When I tried with the US > Northeast subset, I got multipolygons and multilinestring entries. Whe

Re: [gdal-dev] geotransform rotation and gdal_merge

2012-07-23 Thread Chaitanya kumar CH
Dave, The reason you have lat/lon values for each pixel is because they may not be aligned exactly. Even though it is not very 'efficient', you have to define the GCPs for each pixel with the lat/lon values of that pixel. Then you use gdalwarp while forcing use of these GCPs to combine all the ima

Re: [gdal-dev] Oracle support available by default in any OSGeo software

2012-07-23 Thread Ivan Lucena
Hi Nicolas, What operational system do you want to use? Regards, Ivan > ---Original Message--- > From: Nicolas Simon > To: gdal-dev@lists.osgeo.org > Cc: vince.rog...@gmail.com > Subject: [gdal-dev] Oracle support available by default in any OSGeo software > Sent: Jul 23 '12 05:2

Re: [gdal-dev] geotransform rotation and gdal_merge

2012-07-23 Thread David Hoese
Chaitanya, I attempted a few small examples with GCPs and gdalwarp told me: "ERROR 1: Failed to compute GCP transform: Transform is not solvable I tried it with 2 GCPs at the sides from a 1x15 image array and another with every point's GCP defined, both failed with that error. Sorry I forgot

Re: [gdal-dev] OSM Driver and World Planet file (pbf format)

2012-07-23 Thread Smith, Michael ERDC-CRREL-NH
Even, It stopped cleanly (no segfault) at 70%. OS is RHEL 6.2 64 bit. Import time was about 340 min. Command was ogr2ogr -progress -f oci oci:user/pass@tns:tmp planet-latest.osm.pbf -lco dim=2 -lco srid=4326 -lco geometry_name=geometry -lco launder=yes I'm rerunning now with the debug log to a

Re: [gdal-dev] New OGR driver to read OpenStreetMap .osm / .pbf files

2012-07-23 Thread Rahkonen Jukka
Even Rouault wrote: 23. heinäkuuta 2012 13:27 > Le lundi 23 juillet 2012 00:09:05, Jukka Rahkonen a écrit : >> Even Rouault mines-paris.org> writes: >> > > > However, select with SQL feels sub-optimal. >> > > >> > > Yes, when you use ogr2ogr with explicit layer names, there are >> > > optimizatio

[gdal-dev] Coordinate Transformation issue

2012-07-23 Thread Christiaan Janssen
Hi, I've been working with the OGR coordinate transformations for some time and as long as I can remember, when calling the Transform function, no matter what I'm transforming to or from I always need to convert the unit length type of the Z component manually. For example, I've created a "from" C

[gdal-dev] how to create NETCDF with several 3D variables?

2012-07-23 Thread Anton Korosov
Dear list, how to create a NetCDF file with several variables that have more than two dimensions? I have to save time series of several fields (sst, chlorophyll, etc) in one file. I found that in order to create one 3D variable I can add NETCDF_DIM_EXTRA, NETCDF_DIM_time_DEF, NETCDF_DIM_time_

Re: [gdal-dev] New OGR driver: Imageset (Tamas Szekeres)

2012-07-23 Thread Daniel Clewley
Hi Tamas, Sounds like a great idea. I don't know if it's of use but I recently put together a python script to create KMZ files of geotagged photos using the Python Imaging Library to read EXIF data. It also exports a list of photos and coordinates as a CSV file, for loading into a GIS. You co

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Daniel Morissette
If I understand correctly, in the Open() call, this driver would open each image file to read its EXIF info and index the files in memory? This would work fine with a dozen images, but as the number of images increases the performance will suffer a lot and this would become unusable in apps suc

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Nicolas Simon
Hi For me it looks like a variant of gdaltindex with input made from specials fields (EXIF data). Output (shapefile for instance) could be translated into whatever you want through ogr2ogr. Regards Nicolas -Message d'origine- De : gda

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Eli Adam
At one point I used GDAL's ability to access EXIF data along with sed and bash to make a shapefile photo index, like ogrtindex but for photos and points rather than geo-rasters and polygons. It worked ok but had precision issues and I stopped working on it when I found GPSPrune, http://activitywor

Re: [gdal-dev] Ogr: ExecuteSQL with MSSQL and geometry column

2012-07-23 Thread Benjamin
Now, I am able to answer to me. Correct me if I am wrong but : With the MSSQL Driver ,when you execute a statment with SQLExecute() the result is a table without geometry field. Then the in the layer give by "SELECT * FROM my_table WHERE CHART_ID = 'my_id'" the geometry column is consider as a s

Re: [gdal-dev] how to create NETCDF with several 3D variables?

2012-07-23 Thread Etienne Tourigny
Hi glad you like the driver. Interesting that you were able to create a 3d file like that! I had thought of it but never tested. Those NETCDF_DIM_* metadata I added to be able to deal with 3d variables in a clean manner. I'm afraid you cannot combine several variables (or subdatasets as gdal cal

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Etienne Tourigny
It might be worth enhancing gdaltindex, using gdal's native exif file reading. Etienne On Mon, Jul 23, 2012 at 12:38 PM, Nicolas Simon wrote: > Hi > For me it looks like a variant of gdaltindex with input made from > specials fields (EXIF data). > Output (shapefile for instance)

Re: [gdal-dev] how to create NETCDF with several 3D variables?

2012-07-23 Thread Chris Barker
On Mon, Jul 23, 2012 at 7:50 AM, Anton Korosov wrote: > how to create a NetCDF file with several variables that have more than two > dimensions? I"m sure you can get this to work, but... netcdf has a pretty different data model than GDAL -- I suspect you'll be fighting that regularly. You may b

Re: [gdal-dev] OSM Driver and World Planet file (pbf format)

2012-07-23 Thread Smith, Michael ERDC-CRREL-NH
Even, [osmusr@bigserver-proc osm]$ ogr2ogr -progress -f oci oci:user/pass@tns:tmp planet-latest.osm.pbf -lco dim=2 -lco srid=4326 -lco geometry_name=geometry -lco launder=yes --debug on 2>osm_debug.log 0...10...20...30...40...50...60Š70 [osmusr@bigserver-proc osm]$ >From the debug output OCI

Re: [gdal-dev] Oracle support available by default in any OSGeo software

2012-07-23 Thread Ivan Lucena
Nicolas, If you install QGIS from OSGeo4W you should be able to also install the Libs package "gdal-oracle: OGR OCI and GDAL GeoRaster Plugins for Oracle" with the files gdal_GEOR.dll and ogr_OCI.dll. That is all you need in QGIS. But if you don't use OSGeo4W you can grab the same files from Ta

Re: [gdal-dev] how to create NETCDF with several 3D variables?

2012-07-23 Thread Etienne Tourigny
Chris is right - the netcdf driver in gdal was designed to read netcdf data and create netcdf files from other formats, not write complex files. Anything else is a hack - better to use other tools if you want to combine bands, variables, etc. Etienne On Mon, Jul 23, 2012 at 2:07 PM, Chris Barker

[gdal-dev] Updated rgb2pct.py for greyscale images

2012-07-23 Thread Kreiser, Kevin
I ran into a small limitation of rgb2pct.py when processing the http://www.glcf.umd.edu/data/landcover/data.shtml 1km AVHRR landcover data set. Essentially the data is structured such that there is a single color channel in which each pixel has a value between 0 - 14. Where 0 is water and 1-4 ar

Re: [gdal-dev] Oracle support available by default in any OSGeo software

2012-07-23 Thread Ivan Lucena
Hi Vincent, So I think we can agree that OCILIB does not bring any advantage other than some unlikely inconvenience of having OCI header and libraries available. You cannot remove the dependence of having access to an Oracle server anyway. The use of OCILIB was evaluated and discussed during th

Re: [gdal-dev] New OGR driver: Imageset (Tamas Szekeres)

2012-07-23 Thread Tamas Szekeres
Daniel, Thanks for the input, I'm still thinking whether an offline or an online solution would be more sufficient. OGR driver would somewhat be simple even if it's used to convert the data source to shapefile directly (ogr2ogr). Scripting requires the user to set up further environments (Python,

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Tamas Szekeres
Hi Daniel, Thanks for your comments. Your concerns are valid about the performance. But writing a script to convert images to shapefiles would likely provide similar performance. With regards to the usability, having a driver (and the use of ogr2ogr) would be more convenient even if that's used mo

[gdal-dev] encoding problem when reading DXF file

2012-07-23 Thread dequan chen
hi all, I download the latest gdal-19-1600-core.msi from http://www.gisinternals.com/sdk and installed, then copy gdal_csharp.dll, ogr_csharp.dll, osr_csharp.dll etc to read .DXF file. But it has the problem of charactor encoding. My DXF file contains chinese charactor that code is GB2312. If i use

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread taibc
Thanks Mateusz, I edited the nmake.opt by adding below lines: GEOS_DIR = C:/geos-3.3.5 GEOS_LIB = $(GEOS_DIR)/src/geos_c_i.lib GEOS_CFLAGS = -I$(GEOS_DIR)/capi -I$(GEOS_DIR)/include/geos -DHAVE_GEOS Then, I rebuilt GDAL, but still got the error: "GEOS support not enable". Kind regards, Tai _

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread Chaitanya kumar CH
Tai, If your rebuild was successful with geos, the only reason for you to get the error is that the application is accessing the wrong libraries somewhere in your system. Do a clean rebuild and make sure the LD_LIBRARY_PATH and GDAL_DATA are set correctly. On Tue, Jul 24, 2012 at 7:37 AM, taibc

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread taibc
Thanks Chaitanya, I haven't set LD_LIBRARY_PATH and GDAL_DATA yet. Do you know how to set them on Visual C++ 2010 ? Kind regards, Tai From: chaitanya_ch [via OSGeo.org] To: taibc Sent: Tuesday, July 24, 2012 10:38 AM Subject: Re: How to identify a point is

Re: [gdal-dev] How to identify a point is belong to a polygon ?

2012-07-23 Thread Chaitanya kumar CH
Tai, The environment variables can be set at the command prompt temporarily using SET LD_LIBRARY_PATH=C:\path\to\gdal\libraries SET GDAL_DATA=C:\path\to\gdal\libraries\data You can set them in the project settings in VC++. I don't know how. You can also set them system wide at MyComputer->Settin

Re: [gdal-dev] how to create NETCDF with several 3D variables?

2012-07-23 Thread Anton Korosov
Etienne, Chris, thank you very much for your response! I'll take a closer look at this software, though I wish to be dependent on fewer packages. Anton On 07/23/2012 08:09 PM, Etienne Tourigny wrote: Chris is right - the netcdf driver in gdal was designed to read netcdf data and create netc

Re: [gdal-dev] New OGR driver: Imageset

2012-07-23 Thread Rutger
Hey, I really like the idea. But the first thing that came to my mind was graphs (images) instead of photographs. So i would love to see it being general enough so that your not limited to a photo with EXIF data. See for example something like this: http://www.cpc.ncep.noaa.gov/products/global_mo

Re: [gdal-dev] encoding problem when reading DXF file

2012-07-23 Thread Dmitry Baryshnikov
24.07.2012 5:37, dequan chen ?: hi all, I download the latest gdal-19-1600-core.msi from http://www.gisinternals.com/sdk and installed, then copy gdal_csharp.dll, ogr_csharp.dll, osr_csharp.dll etc to read .DXF file. But it has the problem of charactor encoding. My DXF file contains chinese