mirror of
https://github.com/boostorg/geometry.git
synced 2025-05-09 23:24:02 +00:00
Removed adapted/tuple_<cs>.hpp files and added a macro to use instead.
[SVN r71448]
This commit is contained in:
parent
c218a43c57
commit
fc68031c90
@ -13,11 +13,13 @@
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_polygon/point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
int main()
|
||||
{
|
||||
|
@ -13,10 +13,11 @@
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/assign.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
int main(void)
|
||||
|
@ -17,12 +17,12 @@
|
||||
|
||||
#include <boost/geometry/algorithms/area.hpp>
|
||||
#include <boost/geometry/algorithms/centroid.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/geometries/register/ring.hpp>
|
||||
#include <boost/geometry/strategies/strategies.hpp>
|
||||
#include <boost/geometry/util/write_dsv.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
|
@ -35,9 +35,10 @@
|
||||
#include <exception>
|
||||
|
||||
#include <boost/geometry/geometry.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/domains/gis/io/wkt/wkt.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
int main()
|
||||
|
@ -11,8 +11,8 @@
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#ifndef BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_HPP
|
||||
#define BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_HPP
|
||||
#ifndef BOOST_GEOMETRY_GEOMETRIES_ADAPTED_BOOST_TUPLE_HPP
|
||||
#define BOOST_GEOMETRY_GEOMETRIES_ADAPTED_BOOST_TUPLE_HPP
|
||||
|
||||
|
||||
#include <cstddef>
|
||||
@ -24,6 +24,7 @@
|
||||
#include <boost/geometry/core/point_type.hpp>
|
||||
#include <boost/geometry/core/tags.hpp>
|
||||
|
||||
|
||||
namespace boost { namespace geometry
|
||||
{
|
||||
|
||||
@ -86,16 +87,23 @@ struct access
|
||||
};
|
||||
|
||||
|
||||
// The library user has
|
||||
// 1) either to specify the coordinate system using a traits class
|
||||
// 2) or include <boost/geometry/geometries/adapted/tuple_@.hpp>
|
||||
// where @=cartesian,geographic,...
|
||||
|
||||
} // namespace traits
|
||||
#endif // DOXYGEN_NO_TRAITS_SPECIALIZATIONS
|
||||
|
||||
|
||||
}} // namespace boost::geometry
|
||||
|
||||
#endif // BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_HPP
|
||||
|
||||
// Convenience registration macro to bind boost::tuple to a CS
|
||||
#define BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(CoordinateSystem) \
|
||||
namespace boost { namespace geometry { namespace traits { \
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5, \
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10> \
|
||||
struct coordinate_system<boost::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> > \
|
||||
{ \
|
||||
typedef CoordinateSystem type; \
|
||||
}; \
|
||||
}}}
|
||||
|
||||
|
||||
#endif // BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_HPP
|
@ -1,49 +0,0 @@
|
||||
// Boost.Geometry (aka GGL, Generic Geometry Library)
|
||||
|
||||
// Copyright (c) 2008-2011 Bruno Lalande, Paris, France.
|
||||
// Copyright (c) 2008-2011 Barend Gehrels, Amsterdam, the Netherlands.
|
||||
// Copyright (c) 2009-2011 Mateusz Loskot, London, UK.
|
||||
|
||||
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
|
||||
// (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
|
||||
|
||||
// Use, modification and distribution is subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#ifndef BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_CARTESIAN_HPP
|
||||
#define BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_CARTESIAN_HPP
|
||||
|
||||
#ifdef BOOST_GEOMETRY_ADAPTED_TUPLE_COORDINATE_SYSTEM_DEFINED
|
||||
#error Include only one headerfile to register coordinate coordinate_system for adapted tuple
|
||||
#endif
|
||||
|
||||
#define BOOST_GEOMETRY_ADAPTED_TUPLE_COORDINATE_SYSTEM_DEFINED
|
||||
|
||||
|
||||
#include <boost/geometry/geometries/adapted/tuple.hpp>
|
||||
|
||||
|
||||
namespace boost { namespace geometry
|
||||
{
|
||||
|
||||
|
||||
#ifndef DOXYGEN_NO_TRAITS_SPECIALIZATIONS
|
||||
namespace traits
|
||||
{
|
||||
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10>
|
||||
struct coordinate_system<boost::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> >
|
||||
{ typedef cs::cartesian type; };
|
||||
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
}} // namespace boost::geometry
|
||||
|
||||
|
||||
#endif // BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_CARTESIAN_HPP
|
@ -1,49 +0,0 @@
|
||||
// Boost.Geometry (aka GGL, Generic Geometry Library)
|
||||
|
||||
// Copyright (c) 2008-2011 Bruno Lalande, Paris, France.
|
||||
// Copyright (c) 2008-2011 Barend Gehrels, Amsterdam, the Netherlands.
|
||||
// Copyright (c) 2009-2011 Mateusz Loskot, London, UK.
|
||||
|
||||
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
|
||||
// (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
|
||||
|
||||
// Use, modification and distribution is subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#ifndef BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_GEOGRAPHIC_HPP
|
||||
#define BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_GEOGRAPHIC_HPP
|
||||
|
||||
#ifdef BOOST_GEOMETRY_ADAPTED_TUPLE_COORDINATE_SYSTEM_DEFINED
|
||||
#error Include only one headerfile to register coordinate coordinate_system for adapted tuple
|
||||
#endif
|
||||
|
||||
#define BOOST_GEOMETRY_ADAPTED_TUPLE_COORDINATE_SYSTEM_DEFINED
|
||||
|
||||
|
||||
#include <boost/geometry/geometries/adapted/tuple.hpp>
|
||||
|
||||
|
||||
namespace boost { namespace geometry
|
||||
{
|
||||
|
||||
|
||||
#ifndef DOXYGEN_NO_TRAITS_SPECIALIZATIONS
|
||||
namespace traits
|
||||
{
|
||||
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10>
|
||||
struct coordinate_system<boost::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> >
|
||||
{ typedef cs::geographic<degree> type; };
|
||||
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
}} // namespace boost::geometry
|
||||
|
||||
|
||||
#endif // BOOST_GEOMETRY_GEOMETRIES_ADAPTED_TUPLE_GEOGRAPHIC_HPP
|
@ -15,7 +15,7 @@
|
||||
#define BOOST_GEOMETRY_GEOMETRIES_HPP
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/point_xy.hpp>
|
||||
|
@ -20,9 +20,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename Linestring>
|
||||
void check_linestring_2d(Linestring const& line)
|
||||
|
@ -22,9 +22,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_all()
|
||||
|
@ -23,12 +23,14 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <test_common/test_point.hpp>
|
||||
#include <test_geometries/custom_segment.hpp>
|
||||
#include <test_geometries/wrapped_boost_array.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_distance_point()
|
||||
|
@ -17,10 +17,12 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_pair_as_segment.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_2d()
|
||||
|
@ -19,10 +19,12 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_pair_as_segment.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename Point>
|
||||
void test_point_3d()
|
||||
|
@ -21,9 +21,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename T, typename P>
|
||||
void test_point_2d()
|
||||
|
@ -22,7 +22,7 @@
|
||||
#include <boost/geometry/algorithms/correct.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
|
||||
#include <boost/geometry/domains/gis/io/wkt/read_wkt.hpp>
|
||||
@ -33,6 +33,8 @@
|
||||
# include <boost/geometry/extensions/io/svg/svg_mapper.hpp>
|
||||
#endif
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
|
||||
template <typename G1, typename G2, typename Functor, typename T>
|
||||
|
@ -22,9 +22,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_addition()
|
||||
|
@ -22,9 +22,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_all()
|
||||
|
@ -23,7 +23,7 @@
|
||||
#include <boost/geometry/algorithms/make.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
|
||||
#include <boost/geometry/core/cs.hpp>
|
||||
@ -31,6 +31,7 @@
|
||||
#include <boost/geometry/geometries/segment.hpp>
|
||||
#include <boost/geometry/geometries/box.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G>
|
||||
|
@ -17,7 +17,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -25,6 +25,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, int Expected>
|
||||
void test_geometry()
|
||||
|
@ -17,7 +17,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -25,6 +25,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, typename Expected>
|
||||
void test_geometry()
|
||||
|
@ -17,7 +17,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -25,6 +25,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, typename Expected>
|
||||
void test_geometry()
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -24,6 +24,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, int Expected>
|
||||
void test_geometry()
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -24,6 +24,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, typename Expected>
|
||||
void test_geometry()
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -23,6 +23,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, typename Expected>
|
||||
void test_geometry()
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
@ -23,6 +23,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename G, int Expected>
|
||||
void test_geometry()
|
||||
|
@ -15,8 +15,7 @@ test-suite boost-geometry-geometries
|
||||
[ run boost_fusion.cpp ]
|
||||
[ run boost_polygon.cpp ]
|
||||
[ run boost_range.cpp ]
|
||||
[ run boost_tuple_cartesian.cpp ]
|
||||
[ run boost_tuple_geographic.cpp ]
|
||||
[ run boost_tuple.cpp ]
|
||||
[ run box.cpp ]
|
||||
#[ compile-fail custom_linestring.cpp
|
||||
# : # requirements
|
||||
|
@ -46,11 +46,14 @@
|
||||
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian)
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
template <typename G>
|
||||
|
@ -14,9 +14,11 @@
|
||||
#include<boost/geometry/geometry.hpp>
|
||||
#include<boost/geometry/geometries/adapted/boost_array_cartesian.hpp>
|
||||
#include<boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include<boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include<boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include<iostream>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
int test_main(int, char* [])
|
||||
{
|
||||
|
@ -16,9 +16,12 @@
|
||||
#include <boost/geometry/geometries/adapted/fusion.hpp>
|
||||
#include <boost/geometry/geometries/adapted/fusion_cartesian.hpp>
|
||||
#include<boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <iostream>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
struct for_fusion_2d
|
||||
{
|
||||
float x,y;
|
||||
|
@ -10,12 +10,16 @@
|
||||
|
||||
#include <geometry_test_common.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <boost/geometry/algorithms/distance.hpp>
|
||||
#include <boost/geometry/strategies/strategies.hpp>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian)
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_all()
|
||||
{
|
@ -1,36 +0,0 @@
|
||||
// Boost.Geometry (aka GGL, Generic Geometry Library)
|
||||
// Unit Test
|
||||
|
||||
// Copyright (c) 2008-2011 Bruno Lalande, Paris, France.
|
||||
|
||||
// Use, modification and distribution is subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
#include <geometry_test_common.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_geographic.hpp>
|
||||
#include <boost/geometry/algorithms/distance.hpp>
|
||||
#include <boost/geometry/strategies/strategies.hpp>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
template <typename P>
|
||||
void test_all()
|
||||
{
|
||||
P p1, p2;
|
||||
// TODO do something applicable for geographic point types
|
||||
// bg::distance(p1, p2);
|
||||
}
|
||||
|
||||
int test_main(int, char* [])
|
||||
{
|
||||
test_all<boost::tuple<float> >();
|
||||
test_all<boost::tuple<int, int> >();
|
||||
test_all<boost::tuple<double, double, double> >();
|
||||
test_all<boost::tuple<float, float, float, float> >();
|
||||
test_all<boost::tuple<float, float, float, float, float> >();
|
||||
|
||||
return 0;
|
||||
}
|
@ -21,9 +21,11 @@
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/box.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
bg::model::box<P> create_box()
|
||||
|
@ -28,9 +28,11 @@
|
||||
#include <boost/geometry/geometries/adapted/boost_array_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/std_as_linestring.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian)
|
||||
|
||||
//#define TEST_FAIL_CLEAR
|
||||
//#define TEST_FAIL_APPEND
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
||||
|
||||
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <boost/geometry/util/write_dsv.hpp>
|
||||
|
||||
@ -31,6 +31,8 @@
|
||||
#include <test_common/test_point.hpp>
|
||||
#include <test_geometries/custom_segment.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
void test_all()
|
||||
|
@ -24,9 +24,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename Geometry1, typename Geometry2>
|
||||
void test_distance(std::string const& wkt1, std::string const& wkt2, double expected)
|
||||
|
@ -25,10 +25,10 @@
|
||||
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P>
|
||||
|
@ -20,10 +20,12 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename Container>
|
||||
inline std::string coordinates(Container const& points)
|
||||
|
@ -23,13 +23,14 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
#ifdef HAVE_TTMATH
|
||||
# include <boost/geometry/extensions/contrib/ttmath_stub.hpp>
|
||||
#endif
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P, typename PS, typename CalculationType>
|
||||
|
@ -31,7 +31,7 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
@ -39,6 +39,7 @@
|
||||
# include <boost/geometry/extensions/contrib/ttmath_stub.hpp>
|
||||
#endif
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P1, typename P2>
|
||||
|
@ -38,8 +38,9 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/segment.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename R>
|
||||
|
@ -25,9 +25,9 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename P, typename T>
|
||||
|
@ -24,9 +24,11 @@
|
||||
|
||||
#include <boost/geometry/geometries/point.hpp>
|
||||
#include <boost/geometry/geometries/adapted/c_array_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
#include <test_common/test_point.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
struct test_operation
|
||||
{
|
||||
|
@ -19,8 +19,9 @@
|
||||
#include <boost/geometry/domains/gis/io/wkt/read_wkt.hpp>
|
||||
#include <boost/geometry/util/write_dsv.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
|
||||
|
@ -21,7 +21,9 @@
|
||||
#include <boost/geometry/domains/gis/io/wkt/read_wkt.hpp>
|
||||
#include <boost/geometry/util/write_dsv.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <typename View>
|
||||
|
@ -19,7 +19,10 @@
|
||||
#include <boost/geometry/domains/gis/io/wkt/wkt.hpp>
|
||||
#include <boost/geometry/util/write_dsv.hpp>
|
||||
#include <boost/geometry/geometries/geometries.hpp>
|
||||
#include <boost/geometry/geometries/adapted/tuple_cartesian.hpp>
|
||||
#include <boost/geometry/geometries/adapted/boost_tuple.hpp>
|
||||
|
||||
BOOST_GEOMETRY_REGISTER_BOOST_TUPLE_CS(cs::cartesian);
|
||||
|
||||
|
||||
template <bg::iterate_direction Direction, typename Range>
|
||||
void test_forward_or_reverse(Range const& range, std::string const& expected)
|
||||
|
Loading…
x
Reference in New Issue
Block a user