Updated various examples, fixing old paths, etc

[SVN r76915]
This commit is contained in:
Barend Gehrels 2012-02-06 19:46:38 +00:00
parent c018c393f4
commit 890424968c
15 changed files with 110 additions and 20 deletions

View File

@ -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>

View File

@ -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

View File

@ -7,10 +7,10 @@
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="&quot;$(SOCI_ROOT)/src/core&quot;;&quot;$(SOCI_ROOT)/src/backends/postgresql&quot;"
PreprocessorDefinitions="SOCI_USE_BOOST"
PreprocessorDefinitions="SOCI_USE_BOOST;SOCI_LIB_PREFIX=\&quot;libsoci_\&quot;;SOCI_LIB_SUFFIX=\&quot;.so\&quot;"
/>
<UserMacro
Name="SOCI_ROOT"
Value="contrib/soci-3.0.0"
Value="contrib/soci-3.1.0"
/>
</VisualStudioPropertySheet>

View File

@ -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>

View File

@ -181,6 +181,10 @@
RelativePath="$(GD)\gd.c"
>
</File>
<File
RelativePath="$(GD)\gd_color.c"
>
</File>
<File
RelativePath="$(GD)\gd_gd.c"
>

View File

@ -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);

View File

@ -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"
>

View File

@ -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"
>

View File

@ -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"
>

View File

@ -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");

View File

@ -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"
>

View File

@ -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)

View File

@ -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;

View File

@ -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>