123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702 |
- // Boost.Geometry (aka GGL, Generic Geometry Library)
- // Copyright (c) 2015, Oracle and/or its affiliates.
- // Licensed under the Boost Software License version 1.0.
- // http://www.boost.org/users/license.html
- // Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
- #ifndef BOOST_TEST_MODULE
- #define BOOST_TEST_MODULE test_intersection_pointlike_linear
- #endif
- #include <iostream>
- #include <algorithm>
- #include <boost/test/included/unit_test.hpp>
- #include "../test_set_ops_pointlike.hpp"
- #include <boost/geometry/geometries/point.hpp>
- #include <boost/geometry/geometries/linestring.hpp>
- #include <boost/geometry/geometries/segment.hpp>
- #include <boost/geometry/geometries/multi_point.hpp>
- #include <boost/geometry/geometries/multi_linestring.hpp>
- typedef bg::model::point<double, 2, bg::cs::cartesian> point_type;
- typedef bg::model::segment<point_type> segment_type;
- typedef bg::model::linestring<point_type> linestring_type;
- typedef bg::model::multi_point<point_type> multi_point_type;
- typedef bg::model::multi_linestring<linestring_type> multi_linestring_type;
- //===========================================================================
- //===========================================================================
- //===========================================================================
- BOOST_AUTO_TEST_CASE( test_intersection_point_segment )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** POINT / SEGMENT INTERSECTION ***" << std::endl;
- std::cout << std::endl;
- #endif
- typedef point_type P;
- typedef segment_type S;
- typedef multi_point_type MP;
- typedef test_set_op_of_pointlike_geometries
- <
- P, S, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("psi01",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<S>("SEGMENT(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("psi02",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<S>("SEGMENT(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("psi03",
- from_wkt<P>("POINT(1 1)"),
- from_wkt<S>("SEGMENT(0 0,2 2)"),
- from_wkt<MP>("MULTIPOINT(1 1)")
- );
- tester::apply
- ("psi04",
- from_wkt<P>("POINT(3 3)"),
- from_wkt<S>("SEGMENT(0 0,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- }
- BOOST_AUTO_TEST_CASE( test_intersection_point_linestring )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** POINT / LINESTRING INTERSECTION ***" << std::endl;
- std::cout << std::endl;
- #endif
- typedef point_type P;
- typedef linestring_type L;
- typedef multi_point_type MP;
- typedef test_set_op_of_pointlike_geometries
- <
- P, L, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("pli01",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<L>("LINESTRING(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pli02",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<L>("LINESTRING(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("pli03",
- from_wkt<P>("POINT(1 1)"),
- from_wkt<L>("LINESTRING(0 0,2 2)"),
- from_wkt<MP>("MULTIPOINT(1 1)")
- );
- tester::apply
- ("pli04",
- from_wkt<P>("POINT(3 3)"),
- from_wkt<L>("LINESTRING(0 0,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- // linestrings with more than two points
- tester::apply
- ("pli05",
- from_wkt<P>("POINT(1 1)"),
- from_wkt<L>("LINESTRING(0 0,1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT(1 1)")
- );
- tester::apply
- ("pli06",
- from_wkt<P>("POINT(2 2)"),
- from_wkt<L>("LINESTRING(0 0,1 1,4 4)"),
- from_wkt<MP>("MULTIPOINT(2 2)")
- );
- tester::apply
- ("pli07",
- from_wkt<P>("POINT(10 10)"),
- from_wkt<L>("LINESTRING(0 0,1 1,4 4)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pli08",
- from_wkt<P>("POINT(0 1)"),
- from_wkt<L>("LINESTRING(0 0,1 1,4 4)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pli09",
- from_wkt<P>("POINT(4 4)"),
- from_wkt<L>("LINESTRING(0 0,1 1,4 4)"),
- from_wkt<MP>("MULTIPOINT(4 4)")
- );
- tester::apply
- ("pli10",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<L>("LINESTRING(0 0,1 1,4 4)"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- }
- BOOST_AUTO_TEST_CASE( test_intersection_point_multilinestring )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** POINT / MULTILINESTRING INTERSECTION ***" << std::endl;
- std::cout << std::endl;
- #endif
- typedef point_type P;
- typedef multi_linestring_type ML;
- typedef multi_point_type MP;
- typedef test_set_op_of_pointlike_geometries
- <
- P, ML, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("pmli01",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((1 1,2 2))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pmli02",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1))"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("pmli03",
- from_wkt<P>("POINT(1 1)"),
- from_wkt<ML>("MULTILINESTRING((0 0,2 2))"),
- from_wkt<MP>("MULTIPOINT(1 1)")
- );
- tester::apply
- ("pmli04",
- from_wkt<P>("POINT(3 3)"),
- from_wkt<ML>("MULTILINESTRING((0 0,2 2))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- // linestrings with more than two points
- tester::apply
- ("pmli05",
- from_wkt<P>("POINT(1 1)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,2 2))"),
- from_wkt<MP>("MULTIPOINT(1 1)")
- );
- tester::apply
- ("pmli06",
- from_wkt<P>("POINT(2 2)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(2 2)")
- );
- tester::apply
- ("pmli07",
- from_wkt<P>("POINT(10 10)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pmli08",
- from_wkt<P>("POINT(0 1)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pmli09",
- from_wkt<P>("POINT(4 4)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(4 4)")
- );
- tester::apply
- ("pmli10",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- // multilinestrings with more than one linestring
- tester::apply
- ("pmli11",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((-10,-10),(0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("pmli12",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,0 0,10 0),(0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("pmli13",
- from_wkt<P>("POINT(0 0)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,10 0),(0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("pmli14",
- from_wkt<P>("POINT(-20 0)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,10 0),(0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pmli15",
- from_wkt<P>("POINT(0 1)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,10 0),(0 0,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("pmli16",
- from_wkt<P>("POINT(1 0)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,10 0),(-1 0,2 0,20 0))"),
- from_wkt<MP>("MULTIPOINT(1 0)")
- );
- tester::apply
- ("pmli17",
- from_wkt<P>("POINT(1 0)"),
- from_wkt<ML>("MULTILINESTRING((-10 0,10 0),(0 -1,0 2,0 4))"),
- from_wkt<MP>("MULTIPOINT(1 0)")
- );
- }
- BOOST_AUTO_TEST_CASE( test_intersection_multipoint_segment )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** MULTIPOINT / SEGMENT INTERSECTION ***" << std::endl;
- std::cout << std::endl;
- #endif
- typedef multi_point_type MP;
- typedef segment_type S;
- typedef test_set_op_of_pointlike_geometries
- <
- MP, S, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("mpsi01",
- from_wkt<MP>("MULTIPOINT(0 0)"),
- from_wkt<S>("SEGMENT(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi02",
- from_wkt<MP>("MULTIPOINT(0 0)"),
- from_wkt<S>("SEGMENT(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("mpsi03",
- from_wkt<MP>("MULTIPOINT(0 0,0 0)"),
- from_wkt<S>("SEGMENT(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi04",
- from_wkt<MP>("MULTIPOINT(0 0,0 0)"),
- from_wkt<S>("SEGMENT(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpsi05",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,1 0)"),
- from_wkt<S>("SEGMENT(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsf06",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,1 0)"),
- from_wkt<S>("SEGMENT(1 0,2 0)"),
- from_wkt<MP>("MULTIPOINT(1 0)")
- );
- tester::apply
- ("mpsi07",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(0 0,1 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpsi07a",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(0 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)")
- );
- tester::apply
- ("mpsi08",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<S>("SEGMENT(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi09",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(-1 0,1 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpsi10",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(1 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(2 0)")
- );
- tester::apply
- ("mpsi11",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(-1 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)")
- );
- tester::apply
- ("mpsi12",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(3 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi12a",
- from_wkt<MP>("MULTIPOINT(0 0,2 0,0 0)"),
- from_wkt<S>("SEGMENT(3 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi12b",
- from_wkt<MP>("MULTIPOINT(0 0,2 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(3 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi12c",
- from_wkt<MP>("MULTIPOINT(0 0,2 0,0 0,2 0,0 0)"),
- from_wkt<S>("SEGMENT(3 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi13",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(2 0,2 0)"),
- from_wkt<MP>("MULTIPOINT(2 0)")
- );
- tester::apply
- ("mpsi14",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<S>("SEGMENT(0 0,0 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpsi15",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<S>("SEGMENT(0 0,1 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpsi16",
- from_wkt<MP>("MULTIPOINT(0 0,2 0,0 0,2 0,0 0)"),
- from_wkt<S>("SEGMENT(-1 0,10 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0,0 0,2 0,2 0)")
- );
- }
- BOOST_AUTO_TEST_CASE( test_intersection_multipoint_linestring )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** MULTIPOINT / LINESTRING INTERSECTION ***" << std::endl;
- std::cout << std::endl;
- #endif
- typedef multi_point_type MP;
- typedef linestring_type L;
- typedef test_set_op_of_pointlike_geometries
- <
- MP, L, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("mpli01",
- from_wkt<MP>("MULTIPOINT(0 0)"),
- from_wkt<L>("LINESTRING(1 1,2 2,3 3,4 4,5 5)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli02",
- from_wkt<MP>("MULTIPOINT(0 0)"),
- from_wkt<L>("LINESTRING(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0)")
- );
- tester::apply
- ("mpli03",
- from_wkt<MP>("MULTIPOINT(0 0,0 0)"),
- from_wkt<L>("LINESTRING(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli04",
- from_wkt<MP>("MULTIPOINT(0 0,0 0)"),
- from_wkt<L>("LINESTRING(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpli05",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,1 0)"),
- from_wkt<L>("LINESTRING(1 1,2 2)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli06",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,1 0)"),
- from_wkt<L>("LINESTRING(1 0,2 0)"),
- from_wkt<MP>("MULTIPOINT(1 0)")
- );
- tester::apply
- ("mpli07",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(0 0,1 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpli08",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<L>("LINESTRING(0 0,1 1)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli09",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(-1 0,1 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpli10",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(1 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(2 0)")
- );
- tester::apply
- ("mpli10a",
- from_wkt<MP>("MULTIPOINT(2 0,0 0,2 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(1 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(2 0,2 0,2 0)")
- );
- tester::apply
- ("mpli11",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(-1 0,3 0)"),
- from_wkt<MP>("MULTIPOINT(2 0,0 0,0 0)")
- );
- tester::apply
- ("mpli12",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(3 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli13",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(2 0,2 0)"),
- from_wkt<MP>("MULTIPOINT(2 0)")
- );
- tester::apply
- ("mpli14",
- from_wkt<MP>("MULTIPOINT(0 0,0 0,2 0)"),
- from_wkt<L>("LINESTRING(0 0,0 0)"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- tester::apply
- ("mpli15",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<L>("LINESTRING(0 0,1 0,2 0,3 0)"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpli16",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<L>("LINESTRING()"),
- from_wkt<MP>("MULTIPOINT()")
- );
- }
- BOOST_AUTO_TEST_CASE( test_intersection_multipoint_multilinestring )
- {
- #ifdef BOOST_GEOMETRY_TEST_DEBUG
- std::cout << std::endl << std::endl << std::endl;
- std::cout << "*** MULTIPOINT / MULTILINESTRING INTERSECTION ***"
- << std::endl;
- std::cout << std::endl;
- #endif
- typedef multi_point_type MP;
- typedef multi_linestring_type ML;
- typedef test_set_op_of_pointlike_geometries
- <
- MP, ML, MP, bg::overlay_intersection
- > tester;
- tester::apply
- ("mpmli01",
- from_wkt<MP>("MULTIPOINT(0 0,1 0,2 0)"),
- from_wkt<ML>("MULTILINESTRING((1 0,1 1,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(1 0)")
- );
- tester::apply
- ("mpmli02",
- from_wkt<MP>("MULTIPOINT(2 2,3 3,0 0,0 0,2 2,1 1,1 1,1 0,1 0)"),
- from_wkt<ML>("MULTILINESTRING((1 0,1 1,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(2 2,2 2,3 3,1 1,1 1,1 0,1 0)")
- );
- tester::apply
- ("mpmli03",
- from_wkt<MP>("MULTIPOINT(5 5,3 3,0 0,0 0,5 5,1 1,1 1,1 0,1 0)"),
- from_wkt<ML>("MULTILINESTRING((1 0,1 1,1 1,4 4))"),
- from_wkt<MP>("MULTIPOINT(1 0,1 0,3 3,1 1,1 1)")
- );
- tester::apply
- ("mpmli04",
- from_wkt<MP>("MULTIPOINT(0 0,1 1,1 0,1 1)"),
- from_wkt<ML>("MULTILINESTRING((1 0,0 0,1 1,0 0))"),
- from_wkt<MP>("MULTIPOINT(1 0,0 0,1 1,1 1)")
- );
- tester::apply
- ("mpmli05",
- from_wkt<MP>("MULTIPOINT(0 0,1 0,2 0,5 0)"),
- from_wkt<ML>("MULTILINESTRING((0 1,0 0,1 2,1 0),\
- (0 1,2 0,0 10,2 0,2 10,5 10,5 0,5 10))"),
- from_wkt<MP>("MULTIPOINT(0 0,1 0,2 0,5 0)")
- );
- tester::apply
- ("mpmli06",
- from_wkt<MP>("MULTIPOINT(0 0,1 1,1 0,1 1)"),
- from_wkt<ML>("MULTILINESTRING(())"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpmli07",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<ML>("MULTILINESTRING(())"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpmli08",
- from_wkt<MP>("MULTIPOINT()"),
- from_wkt<ML>("MULTILINESTRING((0 0,1 0),(9 0,10 0))"),
- from_wkt<MP>("MULTIPOINT()")
- );
- tester::apply
- ("mpmli09",
- from_wkt<MP>("MULTIPOINT(0 0,1 1,0 0,0 0,0 0,0 0,0 0,0 0,\
- 0 0,0 0,0 0,0 0,0 0)"),
- from_wkt<ML>("MULTILINESTRING((0 0,0 1),(0 0,2 0),(0 0,0 3),\
- (0 0,4 0),(0 0,0 5),(0 0,6 0),(0 0,7 0),(0 0,8 0))"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0,0 0,0 0,0 0,0 0,0 0,\
- 0 0,0 0,0 0,0 0,0 0)")
- );
- tester::apply
- ("mpmli09a",
- from_wkt<MP>("MULTIPOINT(0 0,1 1,0 0)"),
- from_wkt<ML>("MULTILINESTRING((0 0,0 1),(0 0,2 0),(0 0,0 3),\
- (0 0,4 0),(0 0,0 5),(0 0,6 0),(0 0,7 0),(0 0,8 0))"),
- from_wkt<MP>("MULTIPOINT(0 0,0 0)")
- );
- }
|