[Qgis-developer] OSM intergration: first public release
Andreas Neumann
a.neumann at carto.net
Mon Feb 9 10:27:38 EST 2009
Hi Martin,
I tried to compile your plugin but get the following error:
-----------------
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp: In member
function ‘void QgsOSMDataProvider::fetchNode(QgsFeature&,
sqlite3_stmt*, bool, QgsAttributeList&)’:
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:456: error:
‘memset’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:459: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:460: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp: In member
function ‘bool QgsOSMDataProvider::addWay(QgsFeature&)’:
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1250: error:
‘memset’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1253: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1263: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1264: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp: In member
function ‘bool QgsOSMDataProvider::postparsing()’:
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1565: error:
‘memset’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1568: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1585: error:
‘memcpy’ is not a member of ‘std’
/home/an/dev/cpp/qgis/src/providers/osm/osmprovider.cpp:1586: error:
‘memcpy’ is not a member of ‘std’
make[2]: *** [src/providers/osm/CMakeFiles/osmprovider.dir/osmprovider.o]
Error 1
make[1]: *** [src/providers/osm/CMakeFiles/osmprovider.dir/all] Error 2
make: *** [all] Error 2
----------------
I am on Ubuntu 8.10, 64bit; QGIS trunk; QT 4.4.3
Any idea what's wrong here?
Thanks,
Andreas
On Sat, February 7, 2009 11:17 pm, Martin Dobias wrote:
> Hi all,
>
> I'm happy to introduce another piece of software from our labs! This
> time it's OpenStreetMap intergration which comes in two parts:
> - vector data provider - implemented in c++
> - plugin - implemented in python (requires the provider for proper
> functionality)
>
> How to get it working:
> - download the provider:
> http://mapserver.sk/~wonder/qgis/osm_provider-snapshot-090207.tar.gz
> - copy it to source tree into directory src/providers and add the new
> directory in src/providers/CMakeLists.txt
> - do make and make install
> - install the plugin from my sandbox repository:
> http://mapserver.sk/~wonder/qgis/plugins-sandbox.xml
>
> Features:
> - open .osm files
> - download data from OSM server
> - upload changes back to OSM server
>
> OpenStreetMap data model is topological and allows assignment of
> arbitrary tags to any nodes or arcs (called ways in osm). This has
> several drawbacks when doing the integration.
>
> When an .osm file is loaded, the user can select whether he wants to
> load points and/or ways (they're loaded as separate layers). Only
> nodes that are not assigned to any way are loaded in the point layer.
> Ways represent both polylines and polygons (closed way), however
> they're (not yet) recognized and handled only as lines. Not all
> editing tasks can be accomplished with current set of editing tools in
> QGIS, such as joining a way to another with common node or actions
> that work with both nodes and ways. Probably a real topology editing
> should be added (i.e. topology created from one or more vector
> layers).
>
> The next problem are the tags. They can virtually consist of any
> number of key-value pairs. This makes classical approach with fixed
> attributes unusable. We've decided to pack all the tags into one
> attribute (in format "key1"="value1","key2=value2"), in future
> releases we plan to create a simple widget that will explode the list
> and bring a convenient GUI for editing of tags. This also complicates
> symbolization: primary roads are defined by "highway"="primary" tag,
> rivers as "waterway"="river" etc. We've added a possibility to select
> what tags should be accessible directly - if you select "name" and
> "highway", you will be able to apply correct symbols and optionally
> also labeling with the names.
>
> OpenStreetMap file format is XML. We've decided to cache the parsed
> data in sqlite database, so further loads will be much quicker. The
> cached data is put in the same directory and same name as original
> file, with suffix ".db". It contains also all edits you've done in the
> file. There's also upload functionality, but it's still very
> experimental, so I advise you not to use it yet. Anyway there will be
> a switch to new API in about two months and the plugin doesn't support
> it.
>
> Download should work fine - you can download either current extent or
> some specific extent by entering coordinates. The server has limit on
> total number of features to be returned and area, so make sure that
> you're not trying to fetch too big extent. The server sometimes needs
> quite some time to process the query, so be patient :-) It's possible
> to get .osm data also from database dumps, e.g. geofabrik.de.
>
> I would consider this as alpha release, but it should be already
> usable for some basic usage.
>
> Any testing and comments are highly welcome!
>
> Regards
> Martin
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
--
Andreas Neumann
http://www.carto.net/neumann/
http://www.svgopen.org/
More information about the Qgis-developer
mailing list