mirror of
https://github.com/boostorg/geometry.git
synced 2025-05-09 23:24:02 +00:00
Updated various examples, fixing old paths, etc
[SVN r76915]
This commit is contained in:
parent
c018c393f4
commit
890424968c
@ -10,6 +10,10 @@
|
||||
//
|
||||
// Linestring Polygon Overlay Example
|
||||
|
||||
// NOTE: this example is obsolete. Boost.Geometry can now
|
||||
// overlay linestrings/polygons.
|
||||
// This sample will be removed in next version.
|
||||
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
@ -8,11 +8,13 @@
|
||||
|
||||
|
||||
Download gd from
|
||||
http://www.libgd.og/
|
||||
http://www.libgd.org/
|
||||
(currently from: https://bitbucket.org/pierrejoye/gd-libgd/downloads)
|
||||
|
||||
and extract to this folder.
|
||||
(currently: extract from ../src/ into this folder)
|
||||
|
||||
Nothing has to be installed.
|
||||
|
||||
This is used in x02_gd_example.cpp
|
||||
|
||||
|
||||
|
@ -7,10 +7,10 @@
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""$(SOCI_ROOT)/src/core";"$(SOCI_ROOT)/src/backends/postgresql""
|
||||
PreprocessorDefinitions="SOCI_USE_BOOST"
|
||||
PreprocessorDefinitions="SOCI_USE_BOOST;SOCI_LIB_PREFIX=\"libsoci_\";SOCI_LIB_SUFFIX=\".so\""
|
||||
/>
|
||||
<UserMacro
|
||||
Name="SOCI_ROOT"
|
||||
Value="contrib/soci-3.0.0"
|
||||
Value="contrib/soci-3.1.0"
|
||||
/>
|
||||
</VisualStudioPropertySheet>
|
||||
|
@ -27,14 +27,12 @@
|
||||
|
||||
#include <boost/foreach.hpp>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/multi/multi.hpp>
|
||||
#include <boost/geometry/algorithms/area.hpp>
|
||||
#include <boost/geometry.hpp>
|
||||
#include <boost/geometry/multi/geometries/multi_polygon.hpp>
|
||||
|
||||
#include <boost/geometry/extensions/gis/latlong/latlong.hpp>
|
||||
#include <boost/geometry/extensions/gis/geographic/strategies/area_huiller_earth.hpp>
|
||||
|
||||
#include <boost/geometry/io/wkt/wkt.hpp>
|
||||
|
||||
|
||||
#include <gd.h>
|
||||
|
||||
|
@ -181,6 +181,10 @@
|
||||
RelativePath="$(GD)\gd.c"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(GD)\gd_color.c"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(GD)\gd_gd.c"
|
||||
>
|
||||
|
@ -36,7 +36,6 @@
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/io/wkt/wkt.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
@ -209,6 +209,26 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\error.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\factory.cpp"
|
||||
>
|
||||
|
@ -209,6 +209,26 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\error.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\factory.cpp"
|
||||
>
|
||||
|
@ -209,6 +209,26 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\error.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\factory.cpp"
|
||||
>
|
||||
|
@ -28,12 +28,13 @@
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/algorithms/area.hpp>
|
||||
#include <boost/geometry.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/point_xy.hpp>
|
||||
|
||||
#include <boost/geometry/extensions/gis/io/wkb/read_wkb.hpp>
|
||||
#include <boost/geometry/extensions/gis/io/wkb/utility.hpp>
|
||||
#include <boost/geometry/io/wkt/wkt.hpp>
|
||||
|
||||
int main()
|
||||
{
|
||||
@ -65,7 +66,7 @@ int main()
|
||||
if (!boost::geometry::hex2wkb(*it, std::back_inserter(wkb)))
|
||||
throw std::runtime_error("hex2wkb translation failed");
|
||||
|
||||
boost::geometry::model::d2::polygon parcel;
|
||||
boost::geometry::model::polygon<boost::geometry::model::d2::point_xy<double> > parcel;
|
||||
if (!boost::geometry::read_wkb(wkb.begin(), wkb.end(), parcel))
|
||||
throw std::runtime_error("read_wkb failed");
|
||||
|
||||
|
@ -209,6 +209,26 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\error.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\pgsql\"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="$(SOCI_ROOT)\src\backends\postgresql\factory.cpp"
|
||||
>
|
||||
|
@ -18,13 +18,13 @@
|
||||
#include <boost/scoped_array.hpp>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/point_xy.hpp>
|
||||
#include <boost/geometry/multi/geometries/multi_geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/register/point.hpp>
|
||||
#include <boost/geometry/geometries/register/ring.hpp>
|
||||
#include <boost/geometry/multi/multi.hpp>
|
||||
#include <boost/geometry/extensions/algorithms/selected.hpp>
|
||||
#include <boost/geometry/io/wkt/read.hpp>
|
||||
#include <boost/geometry/multi/io/wkt/read.hpp>
|
||||
|
||||
|
||||
// wxWidgets, if these headers are NOT found, adapt include path (and lib path)
|
||||
|
@ -20,8 +20,8 @@
|
||||
#include "shapefil.h"
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/point_xy.hpp>
|
||||
#include <boost/geometry/io/wkt/iomanip.hpp>
|
||||
|
||||
using namespace boost::geometry;
|
||||
|
||||
|
@ -23,13 +23,15 @@
|
||||
#include <boost/foreach.hpp>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/multi/geometries/multi_geometries.hpp>
|
||||
#include <boost/geometry/geometries/point_xy.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/register/point.hpp>
|
||||
#include <boost/geometry/geometries/register/ring.hpp>
|
||||
|
||||
#include <boost/geometry/multi/multi.hpp>
|
||||
#include <boost/geometry/extensions/algorithms/selected.hpp>
|
||||
#include <boost/geometry/io/wkt/wkt.hpp>
|
||||
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user