Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r78182 - in sandbox/gtl: boost/polygon libs/polygon/benchmark libs/polygon/example libs/polygon/test
From: sydorchuk.andriy_at_[hidden]
Date: 2012-04-24 16:02:05


Author: asydorchuk
Date: 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
New Revision: 78182
URL: http://svn.boost.org/trac/boost/changeset/78182

Log:
Renaming directed_line_segment_... to segment_...
Updating Voronoi code accordingly.
Added:
   sandbox/gtl/boost/polygon/segment_concept.hpp
      - copied, changed from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp
   sandbox/gtl/boost/polygon/segment_data.hpp
      - copied, changed from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_data.hpp
   sandbox/gtl/boost/polygon/segment_set_data.hpp
      - copied, changed from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp
   sandbox/gtl/boost/polygon/segment_traits.hpp
      - copied, changed from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp
Removed:
   sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp
   sandbox/gtl/boost/polygon/directed_line_segment_data.hpp
   sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp
   sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp
Text files modified:
   sandbox/gtl/boost/polygon/polygon.hpp | 8
   sandbox/gtl/boost/polygon/segment_concept.hpp | 210 ++++++++++++++++++++--------------------
   sandbox/gtl/boost/polygon/segment_data.hpp | 30 ++--
   sandbox/gtl/boost/polygon/segment_set_data.hpp | 46 ++++----
   sandbox/gtl/boost/polygon/segment_traits.hpp | 12 +-
   sandbox/gtl/boost/polygon/voronoi.hpp | 8
   sandbox/gtl/libs/polygon/benchmark/voronoi_benchmark_segments.cpp | 4
   sandbox/gtl/libs/polygon/example/voronoi_basic_tutorial.cpp | 4
   sandbox/gtl/libs/polygon/test/voronoi_benchmark_test.cpp | 4
   sandbox/gtl/libs/polygon/test/voronoi_builder_test.cpp | 64 ++++++------
   10 files changed, 196 insertions(+), 194 deletions(-)

Deleted: sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
+++ (empty file)
@@ -1,758 +0,0 @@
-/*
- Copyright 2008 Intel Corporation
-
- Use, modification and distribution are 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_POLYGON_DIRECTED_LINE_SEGMENT_CONCEPT_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_CONCEPT_HPP
-#include "isotropy.hpp"
-#include "directed_line_segment_data.hpp"
-#include "directed_line_segment_traits.hpp"
-#include "rectangle_concept.hpp"
-#include "detail/polygon_arbitrary_formation.hpp"
-
-namespace boost { namespace polygon{
- struct directed_line_segment_concept {};
-
- template <typename T>
- struct is_directed_line_segment_concept { typedef gtl_no type; };
- template <>
- struct is_directed_line_segment_concept<directed_line_segment_concept> {
- typedef gtl_yes type;
- };
-
- template <typename T>
- struct is_mutable_directed_line_segment_concept { typedef gtl_no type; };
- template <>
- struct is_mutable_directed_line_segment_concept<directed_line_segment_concept> {
- typedef gtl_yes type;
- };
-
- template <typename T, typename CT>
- struct directed_line_segment_distance_type_by_concept {
- typedef void type;
- };
-
- template <typename T>
- struct directed_line_segment_distance_type_by_concept<T, gtl_yes> {
- typedef typename coordinate_traits<
- typename directed_line_segment_traits<T>::coordinate_type
- >::coordinate_distance type;
- };
-
- template <typename T>
- struct directed_line_segment_distance_type {
- typedef typename directed_line_segment_distance_type_by_concept<
- T,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type type;
- };
-
- template <typename T, typename CT>
- struct directed_line_segment_point_type_by_concept { typedef void type; };
- template <typename T>
- struct directed_line_segment_point_type_by_concept<T, gtl_yes> {
- typedef typename directed_line_segment_traits<T>::point_type type;
- };
-
- template <typename T>
- struct directed_line_segment_point_type {
- typedef typename directed_line_segment_point_type_by_concept<
- T,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type type;
- };
-
- template <typename T, typename CT>
- struct directed_line_segment_coordinate_type_by_concept {
- typedef void type;
- };
-
- template <typename T>
- struct directed_line_segment_coordinate_type_by_concept<T, gtl_yes> {
- typedef typename directed_line_segment_traits<T>::coordinate_type type;
- };
-
- template <typename T>
- struct directed_line_segment_coordinate_type {
- typedef typename directed_line_segment_coordinate_type_by_concept<
- T,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type type;
- };
-
- struct y_s_get : gtl_yes {};
-
- template <typename T>
- typename enable_if<
- typename gtl_and<
- y_s_get,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type,
- typename directed_line_segment_point_type<T>::type
- >::type
- get(const T& segment, direction_1d dir) {
- return directed_line_segment_traits<T>::get(segment, dir);
- }
-
- struct y_s_set : gtl_yes {};
-
- template <typename T, typename point_type>
- typename enable_if<
- typename gtl_and<
- y_s_set,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type,
- void
- >::type
- set(T& segment, direction_1d dir, point_type value) {
- directed_line_segment_mutable_traits<T>::set(segment, dir, value);
- }
-
- struct y_s_construct : gtl_yes {};
-
- template <typename T, typename T2, typename T3>
- typename enable_if<
- typename gtl_and<
- y_s_construct,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type
- >::type,
- T
- >::type
- construct(T2 low_value, T3 high_value) {
- return directed_line_segment_mutable_traits<T>::construct(low_value, high_value);
- }
-
- struct y_s_copy_construct : gtl_yes {};
-
- template <typename T, typename T2>
- typename enable_if<
- typename gtl_and_3<
- y_s_copy_construct,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T2>::type
- >::type
- >::type,
- T
- >::type
- copy_construct(const T2& segment) {
- return construct<T>
- (get(segment, LOW ),
- get(segment, HIGH));
- }
-
- struct y_s_assign : gtl_yes {};
-
- template <typename T1, typename T2>
- typename enable_if<
- typename gtl_and_3<
- y_s_assign,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<T1>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T2>::type
- >::type
- >::type,
- T1
- >::type &
- assign(T1& lvalue, const T2& rvalue) {
- lvalue = copy_construct<T1>(rvalue);
- return lvalue;
- }
-
- struct y_s_equivalence : gtl_yes {};
-
- template <typename T, typename T2>
- typename enable_if<
- typename gtl_and_3<
- y_s_equivalence,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<T2>::type
- >::type
- >::type,
- bool
- >::type
- equivalence(const T& segment1, const T2& segment2) {
- return get(segment1, LOW) == get(segment2, LOW) &&
- get(segment1, HIGH) == get(segment2, HIGH);
- }
-
- struct y_s_on_above_or_below : gtl_yes {};
-
- //-1 for below, 0 for on and 1 for above
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_on_above_or_below,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- bool
- >::type
- on_above_or_below(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type value) {
- typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
- > paf;
- typename paf::Point pt, l, h;
- assign(pt, value);
- assign(l, low(segment));
- assign(h, high(segment));
- return paf::on_above_or_below(pt, typename paf::half_edge(l, h));
- }
-
- struct y_s_contains : gtl_yes {};
-
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_contains,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- bool
- >::type
- contains(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type value,
- bool consider_touch = true ) {
- if(on_above_or_below(segment, value) == 0) {
- rectangle_data<typename directed_line_segment_coordinate_type<segment_type>::type> rect;
- set_points(rect, low(segment), high(segment));
- if(area(rect) == 0.0) {
- if(!consider_touch) {
- return !equivalence(value, low(segment)) &&
- !equivalence(value, high(segment));
- }
- }
- return contains(rect, value, consider_touch);
- }
- return false;
- }
-
- struct y_s_contains2 : gtl_yes {};
-
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_contains2,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- contains(const segment_type& segment,
- const segment_type_2& value,
- bool consider_touch = true) {
- return contains(segment, get(value, LOW), consider_touch) &&
- contains(segment, get(value, HIGH), consider_touch);
- }
-
- struct y_s_low : gtl_yes {};
-
- // get the low point
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_low,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- typename directed_line_segment_point_type<segment_type>::type
- >::type
- low(const segment_type& segment) {
- return get(segment, LOW);
- }
-
- struct y_s_high : gtl_yes {};
-
- // get the high point
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_high,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- typename directed_line_segment_point_type<segment_type>::type
- >::type
- high(const segment_type& segment) {
- return get(segment, HIGH);
- }
-
- struct y_s_center : gtl_yes {};
-
- // get the center point
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_center,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- typename directed_line_segment_point_type<segment_type>::type
- >::type
- center(const segment_type& segment) {
- return construct<typename directed_line_segment_coordinate_type<segment_type>::type>(
- (x(high(segment)) + x(low(segment)))/2,
- (y(high(segment)) + y(low(segment)))/2);
- }
-
- struct y_s_low2 : gtl_yes {};
-
- // set the low point to v
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_low2,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- void
- >::type
- low(segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type v) {
- set(segment, LOW, v);
- }
-
- struct y_s_high2 : gtl_yes {};
-
- // set the high coordinate to v
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_high2,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- void
- >::type
- high(segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type v) {
- set(segment, HIGH, v);
- }
-
- struct y_s_length : gtl_yes {};
-
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_length,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- typename directed_line_segment_point_type<segment_type>::type
- >::type
- length(const segment_type& segment) {
- return euclidean_distance(low(segment), high(segment));
- }
-
- struct y_s_scale_up : gtl_yes {};
-
- // scale segment by factor
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_scale_up,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- scale_up(segment_type& segment,
- typename coordinate_traits<
- typename directed_line_segment_coordinate_type<segment_type>::type
- >::unsigned_area_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, scale_up(l, factor));
- high(segment, scale_up(h, factor));
- return segment;
- }
-
- struct y_s_scale_down : gtl_yes {};
-
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_scale_down,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- scale_down(segment_type& segment,
- typename coordinate_traits<
- typename directed_line_segment_coordinate_type<segment_type>::type
- >::unsigned_area_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, scale_down(l, factor));
- high(segment, scale_down(h, factor));
- return segment;
- }
-
- struct y_s_scale : gtl_yes {};
-
- template <typename segment_type, typename scaling_type>
- typename enable_if<
- typename gtl_and<
- y_s_scale,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- scale(segment_type& segment, scaling_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, scale(l, factor));
- high(segment, scale(h, factor));
- return segment;
- }
-
-
- struct y_s_transform : gtl_yes {};
-
- template <typename segment_type, typename transform_type>
- typename enable_if<
- typename gtl_and<
- y_s_transform,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- transform(segment_type& segment, const transform_type& val) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, transform(l, val));
- high(segment, transform(h, val));
- return segment;
- }
-
- struct y_s_move : gtl_yes {};
-
- // move segment by delta
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_move,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- move(segment_type& segment, orientation_2d orient,
- typename directed_line_segment_coordinate_type<segment_type>::type displacement) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, move(l, orient, displacement));
- high(segment, move(h, orient, displacement));
- return segment;
- }
-
- struct y_s_convolve : gtl_yes {};
-
- // convolve this with b
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_convolve,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- convolve(segment_type& segment,
- const typename directed_line_segment_point_type<segment_type>::type& b) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, convolve(l, b));
- high(segment, convolve(h, b));
- return segment;
- }
-
- struct y_s_deconvolve : gtl_yes {};
-
- // deconvolve this with b
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_deconvolve,
- typename is_mutable_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- segment_type
- >::type &
- deconvolve(segment_type& segment,
- const typename directed_line_segment_point_type<segment_type>::type& b) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
- low(segment, deconvolve(l, b));
- high(segment, deconvolve(h, b));
- return segment;
- }
-
- struct y_s_e_dist1 : gtl_yes {};
-
- // distance from a point to a segment
- template <typename segment_type>
- typename enable_if<
- typename gtl_and<
- y_s_e_dist1,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type
- >::type,
- typename directed_line_segment_distance_type<segment_type>::type
- >::type
- euclidean_distance(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type position) {
- typedef typename directed_line_segment_distance_type<segment_type>::type Unit;
- Unit x1 = x(low(segment));
- Unit y1 = y(low(segment));
- Unit x2 = x(high(segment));
- Unit y2 = y(high(segment));
- Unit X = x(position);
- Unit Y = y(position);
- Unit A = X - x1;
- Unit B = Y - y1;
- Unit C = x2 - x1;
- Unit D = y2 - y1;
- Unit length_sq = C * C + D * D;
- Unit param = (A * C + B * D)/length_sq;
- if(param > 1.0) {
- return euclidean_distance(high(segment), position);
- } else if(param < 0.0) {
- return euclidean_distance(low(segment), position);
- }
- Unit denom = sqrt(length_sq);
- if(denom == 0.0)
- return 0.0;
- Unit result = (A * D - C * B) / denom;
- if(result < 0.0)
- result *= -1;
- return result;
- }
-
- struct y_s_e_dist2 : gtl_yes {};
-
- // distance between two segments
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_e_dist2,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- typename directed_line_segment_distance_type<segment_type>::type
- >::type
- euclidean_distance(const segment_type& segment,
- const segment_type_2& b) {
- typename directed_line_segment_distance_type<segment_type>::type result1 =
- euclidean_distance(segment, low(b)),
- result2 = euclidean_distance(segment, high(b));
- if(result2 < result1) result1 = result2;
- return result1;
- }
-
- struct y_s_e_intersects : gtl_yes {};
-
- // check if Interval b intersects `this` Interval
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_e_intersects,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- intersects(const segment_type& segment,
- const segment_type_2& b,
- bool consider_touch = true) {
- if(consider_touch) {
- if(low(segment) == low(b) ||
- low(segment) == high(b) ||
- high(segment) == low(b) ||
- high(segment) == high(b))
- return true;
- }
- typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
- > paf;
- typename paf::Point l, h, l2, h2;
- assign(l, low(segment));
- assign(h, high(segment));
- assign(l2, low(b));
- assign(h2, high(b));
- return paf::intersects(typename paf::half_edge(l, h),
- typename paf::half_edge(l2, h2));
- }
-
- struct y_s_e_bintersect : gtl_yes {};
-
- // check if Interval b partially overlaps `this` Interval
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_e_bintersect,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- boundaries_intersect(const segment_type& segment, const segment_type_2& b,
- bool consider_touch = true) {
- return (contains(segment, low(b), consider_touch) ||
- contains(segment, high(b), consider_touch)) &&
- (contains(b, low(segment), consider_touch) ||
- contains(b, high(segment), consider_touch));
- }
-
- struct y_s_abuts1 : gtl_yes {};
-
- // check if they are end to end
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_abuts1,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- abuts(const segment_type& segment,
- const segment_type_2& b,
- direction_1d dir) {
- return dir.to_int() ? equivalence(low(b) , high(segment)) :
- equivalence(low(segment) , high(b));
- }
-
- struct y_s_abuts2 : gtl_yes {};
-
- // check if they are end to end
- template <typename segment_type, typename segment_type_2>
- typename enable_if<
- typename gtl_and_3<
- y_s_abuts2,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- abuts(const segment_type& segment, const segment_type_2& b) {
- return abuts(segment, b, HIGH) || abuts(segment, b, LOW);
- }
-
- struct y_s_intersect : gtl_yes {};
-
- // set point to the intersection of segment and b
- template <typename point_type,
- typename segment_type,
- typename segment_type_2>
- typename enable_if<
- typename gtl_and_4<
- y_s_intersect,
- typename is_mutable_point_concept<
- typename geometry_concept<point_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type>::type
- >::type,
- typename is_directed_line_segment_concept<
- typename geometry_concept<segment_type_2>::type
- >::type
- >::type,
- bool
- >::type
- intersection(point_type& intersection,
- const segment_type& segment,
- const segment_type_2& b,
- bool projected = false,
- bool round_closest = false) {
- typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
- > paf;
- typename paf::Point pt;
- typename paf::Point l, h, l2, h2;
- assign(l, low(segment));
- assign(h, high(segment));
- assign(l2, low(b));
- assign(h2, high(b));
- typename paf::half_edge he1(l, h), he2(l2, h2);
- typename paf::compute_intersection_pack pack;
- if(pack.compute_intersection(pt, he1, he2, projected, round_closest)) {
- assign(intersection, pt);
- return true;
- }
- return false;
- }
-
- template <class T>
- template <class T2>
- directed_line_segment_data<T>& directed_line_segment_data<T>::operator=(const T2& rvalue) {
- assign(*this, rvalue);
- return *this;
- }
-
- template <typename T>
- struct geometry_concept<directed_line_segment_data<T> > {
- typedef directed_line_segment_concept type;
- };
-}
-}
-#endif

Deleted: sandbox/gtl/boost/polygon/directed_line_segment_data.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/directed_line_segment_data.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
+++ (empty file)
@@ -1,85 +0,0 @@
-/*
- Copyright 2008 Intel Corporation
-
- Use, modification and distribution are 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_POLYGON_DIRECTED_LINE_SEGMENT_DATA_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_DATA_HPP
-#include "isotropy.hpp"
-#include "point_data.hpp"
-namespace boost { namespace polygon{
- template <typename T>
- class directed_line_segment_data {
- public:
- typedef T coordinate_type;
- typedef point_data<T> point_type;
- inline directed_line_segment_data()
-#ifndef BOOST_POLYGON_MSVC
- :points_()
-#endif
- {}
- inline directed_line_segment_data(point_type low, point_type high)
-#ifndef BOOST_POLYGON_MSVC
- :points_()
-#endif
- {
- points_[LOW] = low; points_[HIGH] = high;
- }
- inline directed_line_segment_data(const directed_line_segment_data& that)
-#ifndef BOOST_POLYGON_MSVC
- :points_()
-#endif
- {
- (*this) = that;
- }
- inline directed_line_segment_data& operator=(
- const directed_line_segment_data& that) {
- points_[0] = that.points_[0]; points_[1] = that.points_[1];
- return *this;
- }
- template <typename T2>
- inline directed_line_segment_data& operator=(const T2& rvalue);
- inline point_type get(direction_1d dir) const {
- return points_[dir.to_int()];
- }
- inline point_type low() const { return points_[0]; }
- inline point_type low(point_type low) {
- points_[0] = low;
- return *this;
- }
- inline point_type high() const { return points_[1]; }
- inline point_type high(point_type high) {
- points_[1] = high;
- return *this;
- }
- inline bool operator==(const directed_line_segment_data& that) const {
- return low() == that.low() && high() == that.high(); }
- inline bool operator!=(const directed_line_segment_data& that) const {
- return low() != that.low() || high() != that.high(); }
- inline bool operator<(const directed_line_segment_data& that) const {
- if(points_[0] < that.points_[0]) return true;
- if(points_[0] > that.points_[0]) return false;
- if(points_[1] < that.points_[1]) return true;
- return false;
- }
- inline bool operator<=(const directed_line_segment_data& that) const {
- return !(that < *this);
- }
- inline bool operator>(const directed_line_segment_data& that) const {
- return that < *this;
- }
- inline bool operator>=(const directed_line_segment_data& that) const {
- return !((*this) < that);
- }
- inline void set(direction_1d dir, point_type value) {
- points_[dir.to_int()] = value;
- }
-
- private:
- point_type points_[2];
-};
-}
-}
-#endif

Deleted: sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
+++ (empty file)
@@ -1,271 +0,0 @@
-/*
- Copyright 2008 Intel Corporation
-
- Use, modification and distribution are 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_POLYGON_DIRECTED_LINE_SEGMENT_SET_DATA_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_SET_DATA_HPP
-
-namespace boost { namespace polygon{
- template <typename T>
- class directed_line_segment_set_data {
- public:
- typedef T coordinate_type;
- typedef point_data<T> point_type;
- typedef directed_line_segment_data<T> directed_line_segment_type;
- typedef std::vector<directed_line_segment_type> value_type;
- typedef typename std::vector<directed_line_segment_type>::const_iterator iterator_type;
-
- inline directed_line_segment_set_data() : data_(), dirty_(false), unsorted_(false) {}
- inline directed_line_segment_set_data(const directed_line_segment_set_data& that):
- data_(that.data_), dirty_(that.dirty_), unsorted_(that.unsorted_) {}
- inline directed_line_segment_set_data& operator=(const directed_line_segment_set_data& that) {
- if(this == &that) return *this;
- data_ = that.data_;
- dirty_ = that.dirty_;
- unsorted_ = that.unsorted_;
- return *this;
- }
- template <typename T2>
- inline directed_line_segment_set_data& operator=(const T2& rvalue) {
- data_.clear();
- bool unsorted = !sorted(rvalue);
- bool dirty = !dirty(rvalue);
- insert(begin(rvalue), end(rvalue));
- unsorted_ = unsorted;
- dirty_ = dirty;
- return *this;
- }
-
- inline bool operator==(const directed_line_segment_set_data& that) const {
- clean();
- that.clean();
- sort();
- that.sort();
- return data_ == that.data_;
- }
- inline bool operator!=(const directed_line_segment_set_data& that) const {
- return !(*this == that);
- }
-
- template <typename iT>
- inline void insert(iT begin_segments, iT end_segments) {
- data_.clear();
- for(; begin_segments != end_segments; ++begin_segments) {
- insert(*begin_segments);
- }
- }
-
- template <typename ST>
- inline void insert(ST segment) {
- unsorted_ = true;
- dirty_ = true;
- directed_line_segment_type tmp_seg;
- assign(tmp_seg, segment);
- data_.push_back(tmp_seg);
- }
-
- inline void clear() { data_.clear(); unsorted_ = false; dirty_ = false; }
-
- inline iterator_type begin() const {
- return data_.begin();
- }
-
- inline iterator_type end() const {
- return data_.end();
- }
-
- const value_type& value() const {
- return data_;
- }
-
- template <typename output_container>
- inline void get(output_container& output) const {
- for(std::size_t i = 0; i < size(); ++i) {
- output.push_back(typename output_container::value_type());
- assign(output.back(), data_[i]);
- }
- }
-
- inline bool empty() const { return data_.empty(); }
-
- inline std::size_t size() const { clean(); return data_.size(); }
-
- inline std::size_t capacity() const { return data_.capacity(); }
-
- inline void reserve(std::size_t size) { return data_.reserve(size); }
-
- inline bool sorted() const { return !unsorted_; }
-
- inline bool dirty() const { return dirty_; }
-
- void clean() const {
- if (!dirty_) return;
- typedef T Unit;
- typedef typename scanline_base<Unit>::Point Point;
- typedef typename scanline_base<Unit>::half_edge half_edge;
- typedef int segment_id;
- std::vector<std::pair<half_edge, segment_id> > half_edges;
- std::vector<std::pair<half_edge, segment_id> > half_edges_out;
- segment_id id = 0;
- half_edges.reserve(data_.size());
- for(iterator_type itr = begin(); itr != end(); ++itr) {
- Point l = (*itr).low();
- Point h = (*itr).high();
- half_edges.push_back(std::make_pair(half_edge(l, h), id++));
- }
- half_edges_out.reserve(half_edges.size());
- //apparently no need to pre-sort data when calling validate_scan
- line_intersection<Unit>::validate_scan(half_edges_out, half_edges.begin(), half_edges.end());
- value_type result;
- result.reserve(half_edges_out.size());
- for(std::size_t i = 0; i < half_edges_out.size(); ++i) {
- id = half_edges_out[i].second;
- Point l = half_edges_out[i].first.first;
- Point h = half_edges_out[i].first.second;
- directed_line_segment_type orig_seg = data_[id];
- if(orig_seg.high() < orig_seg.low())
- std::swap(l, h);
- result.push_back(directed_line_segment_type(l, h));
- }
- std::swap(result, data_);
- dirty_ = false;
- unsorted_ = true;
- };
-
- void sort() const{
- if(unsorted_) {
- polygon_sort(data_.begin(), data_.end());
- unsorted_ = false;
- }
- }
-
- template <typename input_iterator_type>
- void set(input_iterator_type input_begin, input_iterator_type input_end) {
- clear();
- reserve(std::distance(input_begin,input_end));
- insert(input_begin, input_end);
- dirty_ = true;
- unsorted_ = true;
- }
-
- void set(const value_type& value) {
- data_ = value;
- dirty_ = true;
- unsorted_ = true;
- }
-
- template <typename rectangle_type>
- bool extents(rectangle_type& rect) {
- if(empty()) return false;
- bool first_iteration = true;
- for(iterator_type itr = begin();
- itr != end(); ++itr) {
- rectangle_type edge_box;
- set_points(edge_box, (*itr).low(), (*itr).high());
- if(first_iteration)
- rect = edge_box;
- else
- encompass(rect, edge_box);
- first_iteration = false;
- }
- return true;
- }
-
- template <typename transform_type>
- inline directed_line_segment_set_data&
- transform(const transform_type& tr) {
- for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
- point_type l = (*itr).low();
- point_type h = (*itr).high();
- ::boost::polygon::transform(l, tr);
- ::boost::polygon::transform(h, tr);
- (*itr).low(l);
- (*itr).high(h);
- }
- unsorted_ = true;
- return *this;
- }
-
- inline directed_line_segment_set_data&
- scale_up(typename coordinate_traits<coordinate_type>::unsigned_area_type factor) {
- for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
- point_type l = (*itr).low();
- point_type h = (*itr).high();
- ::boost::polygon::scale_up(l, factor);
- ::boost::polygon::scale_up(h, factor);
- (*itr).low(l);
- (*itr).high(h);
- }
- return *this;
- }
-
- inline directed_line_segment_set_data&
- scale_down(typename coordinate_traits<coordinate_type>::unsigned_area_type factor) {
- for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
- point_type l = (*itr).low();
- point_type h = (*itr).high();
- ::boost::polygon::scale_down(l, factor);
- ::boost::polygon::scale_down(h, factor);
- (*itr).low(l);
- (*itr).high(h);
- }
- return *this;
- }
-
- template <typename scaling_type>
- inline directed_line_segment_set_data& scale(const scaling_type& scaling) {
- for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
- point_type l = (*itr).low();
- point_type h = (*itr).high();
- ::boost::polygon::scale(l, scaling);
- ::boost::polygon::scale(h, scaling);
- (*itr).low(l);
- (*itr).high(h);
- }
- return *this;
- }
-
- template <typename cT>
- std::size_t get_intersection_points(cT& output_points) const {
- typedef T Unit;
- typedef typename scanline_base<Unit>::Point Point;
- typedef typename scanline_base<Unit>::half_edge half_edge;
- typedef int segment_id;
- std::vector<std::pair<half_edge, segment_id> > half_edges;
- std::vector<std::pair<half_edge, segment_id> > half_edges_out;
- segment_id id = 0;
- half_edges.reserve(data_.size());
- for(iterator_type itr = begin(); itr != end(); ++itr) {
- Point l = (*itr).low();
- Point h = (*itr).high();
- half_edges.push_back(std::make_pair(half_edge(l, h), id++));
- }
- half_edges_out.reserve(half_edges.size());
- std::vector<std::set<Point> > intersection_points(half_edges.size(), std::set<Point>());
- line_intersection<Unit>::validate_scan_divide_and_conquer(intersection_points, half_edges.begin(), half_edges.end());
- std::vector<Point> tmp_points;
- for(std::size_t i = 0; i < intersection_points.size(); ++i) {
- typename std::set<Point>::iterator itr2 = intersection_points[i].begin();
- for(; itr2 != intersection_points[i].end(); ++itr2)
- if(data_[i].low() != *itr2 && data_[i].high() != *itr2)
- tmp_points.push_back(*itr2);
- }
- polygon_sort(tmp_points.begin(), tmp_points.end());
- typename std::vector<Point>::iterator new_end = std::unique(tmp_points.begin(), tmp_points.end());
- output_points.insert(output_points.end(), tmp_points.begin(), new_end);
- return std::distance(tmp_points.begin(), new_end);
- }
-
-
-private:
- mutable value_type data_;
- mutable bool dirty_;
- mutable bool unsorted_;
-};
-
-}
-}
-#endif

Deleted: sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
+++ (empty file)
@@ -1,42 +0,0 @@
-/*
- Copyright 2008 Intel Corporation
-
- Use, modification and distribution are 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_POLYGON_DIRECTED_LINE_SEGMENT_TRAITS_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_TRAITS_HPP
-namespace boost { namespace polygon{
- template <typename T>
- struct directed_line_segment_traits {
- typedef typename T::coordinate_type coordinate_type;
- typedef typename T::point_type point_type;
-
- static inline point_type get(const T& segment, direction_1d dir) {
- return segment.get(dir);
- }
- };
-
- template <typename T>
- struct directed_line_segment_mutable_traits {
- template <typename Point1>
- static inline void set(T& segment, direction_1d dir, const Point1& value) {
- typename directed_line_segment_traits<T>::point_type p1;
- assign(p1, value);
- segment.set(dir, value);
- }
-
- template <typename Point1, typename Point2>
- static inline T construct(const Point1& low_value,
- const Point2& high_value) {
- typename directed_line_segment_traits<T>::point_type p1, p2;
- assign(p1, low_value);
- assign(p2, high_value);
- return T(p1, p2);
- }
- };
-}
-}
-#endif
-

Modified: sandbox/gtl/boost/polygon/polygon.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/polygon.hpp (original)
+++ sandbox/gtl/boost/polygon/polygon.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -88,9 +88,9 @@
 
 #include "polygon_set_concept.hpp"
 
-#include "directed_line_segment_data.hpp"
-#include "directed_line_segment_set_data.hpp"
-#include "directed_line_segment_traits.hpp"
-#include "directed_line_segment_concept.hpp"
+#include "segment_data.hpp"
+#include "segment_set_data.hpp"
+#include "segment_traits.hpp"
+#include "segment_concept.hpp"
 
 #endif

Copied: sandbox/gtl/boost/polygon/segment_concept.hpp (from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp)
==============================================================================
--- /sandbox/gtl/boost/polygon/directed_line_segment_concept.hpp (original)
+++ sandbox/gtl/boost/polygon/segment_concept.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -5,85 +5,85 @@
   Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
   http://www.boost.org/LICENSE_1_0.txt).
 */
-#ifndef BOOST_POLYGON_DIRECTED_LINE_SEGMENT_CONCEPT_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_CONCEPT_HPP
+#ifndef BOOST_POLYGON_SEGMENT_CONCEPT_HPP
+#define BOOST_POLYGON_SEGMENT_CONCEPT_HPP
 #include "isotropy.hpp"
-#include "directed_line_segment_data.hpp"
-#include "directed_line_segment_traits.hpp"
+#include "segment_data.hpp"
+#include "segment_traits.hpp"
 #include "rectangle_concept.hpp"
 #include "detail/polygon_arbitrary_formation.hpp"
 
 namespace boost { namespace polygon{
- struct directed_line_segment_concept {};
+ struct segment_concept {};
  
   template <typename T>
- struct is_directed_line_segment_concept { typedef gtl_no type; };
+ struct is_segment_concept { typedef gtl_no type; };
   template <>
- struct is_directed_line_segment_concept<directed_line_segment_concept> {
+ struct is_segment_concept<segment_concept> {
     typedef gtl_yes type;
   };
 
   template <typename T>
- struct is_mutable_directed_line_segment_concept { typedef gtl_no type; };
+ struct is_mutable_segment_concept { typedef gtl_no type; };
   template <>
- struct is_mutable_directed_line_segment_concept<directed_line_segment_concept> {
+ struct is_mutable_segment_concept<segment_concept> {
     typedef gtl_yes type;
   };
 
   template <typename T, typename CT>
- struct directed_line_segment_distance_type_by_concept {
+ struct segment_distance_type_by_concept {
     typedef void type;
   };
 
   template <typename T>
- struct directed_line_segment_distance_type_by_concept<T, gtl_yes> {
+ struct segment_distance_type_by_concept<T, gtl_yes> {
     typedef typename coordinate_traits<
- typename directed_line_segment_traits<T>::coordinate_type
+ typename segment_traits<T>::coordinate_type
>::coordinate_distance type;
   };
 
   template <typename T>
- struct directed_line_segment_distance_type {
- typedef typename directed_line_segment_distance_type_by_concept<
+ struct segment_distance_type {
+ typedef typename segment_distance_type_by_concept<
       T,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type type;
   };
 
   template <typename T, typename CT>
- struct directed_line_segment_point_type_by_concept { typedef void type; };
+ struct segment_point_type_by_concept { typedef void type; };
   template <typename T>
- struct directed_line_segment_point_type_by_concept<T, gtl_yes> {
- typedef typename directed_line_segment_traits<T>::point_type type;
+ struct segment_point_type_by_concept<T, gtl_yes> {
+ typedef typename segment_traits<T>::point_type type;
   };
 
   template <typename T>
- struct directed_line_segment_point_type {
- typedef typename directed_line_segment_point_type_by_concept<
+ struct segment_point_type {
+ typedef typename segment_point_type_by_concept<
       T,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type type;
   };
 
   template <typename T, typename CT>
- struct directed_line_segment_coordinate_type_by_concept {
+ struct segment_coordinate_type_by_concept {
     typedef void type;
   };
   
   template <typename T>
- struct directed_line_segment_coordinate_type_by_concept<T, gtl_yes> {
- typedef typename directed_line_segment_traits<T>::coordinate_type type;
+ struct segment_coordinate_type_by_concept<T, gtl_yes> {
+ typedef typename segment_traits<T>::coordinate_type type;
   };
 
   template <typename T>
- struct directed_line_segment_coordinate_type {
- typedef typename directed_line_segment_coordinate_type_by_concept<
+ struct segment_coordinate_type {
+ typedef typename segment_coordinate_type_by_concept<
       T,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type type;
@@ -95,14 +95,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_get,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type,
- typename directed_line_segment_point_type<T>::type
+ typename segment_point_type<T>::type
>::type
   get(const T& segment, direction_1d dir) {
- return directed_line_segment_traits<T>::get(segment, dir);
+ return segment_traits<T>::get(segment, dir);
   }
 
   struct y_s_set : gtl_yes {};
@@ -111,14 +111,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_set,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type,
     void
>::type
   set(T& segment, direction_1d dir, point_type value) {
- directed_line_segment_mutable_traits<T>::set(segment, dir, value);
+ segment_mutable_traits<T>::set(segment, dir, value);
   }
 
   struct y_s_construct : gtl_yes {};
@@ -127,14 +127,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_construct,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<T>::type
>::type
>::type,
     T
>::type
   construct(T2 low_value, T3 high_value) {
- return directed_line_segment_mutable_traits<T>::construct(low_value, high_value);
+ return segment_mutable_traits<T>::construct(low_value, high_value);
   }
 
   struct y_s_copy_construct : gtl_yes {};
@@ -143,10 +143,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_copy_construct,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<T>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T2>::type
>::type
>::type,
@@ -164,10 +164,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_assign,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
           typename geometry_concept<T1>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
           typename geometry_concept<T2>::type
>::type
>::type,
@@ -184,10 +184,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_equivalence,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<T2>::type
>::type
>::type,
@@ -205,16 +205,16 @@
   typename enable_if<
     typename gtl_and<
       y_s_on_above_or_below,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     bool
>::type
   on_above_or_below(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type value) {
+ typename segment_point_type<segment_type>::type value) {
     typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
+ typename segment_coordinate_type<segment_type>::type
> paf;
     typename paf::Point pt, l, h;
     assign(pt, value);
@@ -229,17 +229,17 @@
   typename enable_if<
     typename gtl_and<
       y_s_contains,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     bool
>::type
   contains(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type value,
+ typename segment_point_type<segment_type>::type value,
            bool consider_touch = true ) {
     if(on_above_or_below(segment, value) == 0) {
- rectangle_data<typename directed_line_segment_coordinate_type<segment_type>::type> rect;
+ rectangle_data<typename segment_coordinate_type<segment_type>::type> rect;
       set_points(rect, low(segment), high(segment));
       if(area(rect) == 0.0) {
         if(!consider_touch) {
@@ -258,10 +258,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_contains2,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -281,11 +281,11 @@
   typename enable_if<
     typename gtl_and<
       y_s_low,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
- typename directed_line_segment_point_type<segment_type>::type
+ typename segment_point_type<segment_type>::type
>::type
   low(const segment_type& segment) {
     return get(segment, LOW);
@@ -298,11 +298,11 @@
   typename enable_if<
     typename gtl_and<
       y_s_high,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
- typename directed_line_segment_point_type<segment_type>::type
+ typename segment_point_type<segment_type>::type
>::type
   high(const segment_type& segment) {
     return get(segment, HIGH);
@@ -315,14 +315,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_center,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
- typename directed_line_segment_point_type<segment_type>::type
+ typename segment_point_type<segment_type>::type
>::type
   center(const segment_type& segment) {
- return construct<typename directed_line_segment_coordinate_type<segment_type>::type>(
+ return construct<typename segment_coordinate_type<segment_type>::type>(
         (x(high(segment)) + x(low(segment)))/2,
         (y(high(segment)) + y(low(segment)))/2);
   }
@@ -334,14 +334,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_low2,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     void
>::type
   low(segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type v) {
+ typename segment_point_type<segment_type>::type v) {
     set(segment, LOW, v);
   }
   
@@ -352,14 +352,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_high2,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     void
>::type
   high(segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type v) {
+ typename segment_point_type<segment_type>::type v) {
     set(segment, HIGH, v);
   }
 
@@ -369,11 +369,11 @@
   typename enable_if<
     typename gtl_and<
       y_s_length,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
- typename directed_line_segment_point_type<segment_type>::type
+ typename segment_point_type<segment_type>::type
>::type
   length(const segment_type& segment) {
     return euclidean_distance(low(segment), high(segment));
@@ -386,7 +386,7 @@
   typename enable_if<
     typename gtl_and<
       y_s_scale_up,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
@@ -394,9 +394,9 @@
>::type &
   scale_up(segment_type& segment,
            typename coordinate_traits<
- typename directed_line_segment_coordinate_type<segment_type>::type
+ typename segment_coordinate_type<segment_type>::type
>::unsigned_area_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, scale_up(l, factor));
     high(segment, scale_up(h, factor));
     return segment;
@@ -408,7 +408,7 @@
   typename enable_if<
     typename gtl_and<
       y_s_scale_down,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
@@ -416,9 +416,9 @@
>::type &
   scale_down(segment_type& segment,
              typename coordinate_traits<
- typename directed_line_segment_coordinate_type<segment_type>::type
+ typename segment_coordinate_type<segment_type>::type
>::unsigned_area_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, scale_down(l, factor));
     high(segment, scale_down(h, factor));
     return segment;
@@ -430,14 +430,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_scale,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     segment_type
>::type &
   scale(segment_type& segment, scaling_type factor) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, scale(l, factor));
     high(segment, scale(h, factor));
     return segment;
@@ -450,14 +450,14 @@
   typename enable_if<
     typename gtl_and<
       y_s_transform,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     segment_type
>::type &
   transform(segment_type& segment, const transform_type& val) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, transform(l, val));
     high(segment, transform(h, val));
     return segment;
@@ -470,15 +470,15 @@
   typename enable_if<
     typename gtl_and<
       y_s_move,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     segment_type
>::type &
   move(segment_type& segment, orientation_2d orient,
- typename directed_line_segment_coordinate_type<segment_type>::type displacement) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ typename segment_coordinate_type<segment_type>::type displacement) {
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, move(l, orient, displacement));
     high(segment, move(h, orient, displacement));
     return segment;
@@ -491,15 +491,15 @@
   typename enable_if<
     typename gtl_and<
       y_s_convolve,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     segment_type
>::type &
   convolve(segment_type& segment,
- const typename directed_line_segment_point_type<segment_type>::type& b) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ const typename segment_point_type<segment_type>::type& b) {
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, convolve(l, b));
     high(segment, convolve(h, b));
     return segment;
@@ -512,36 +512,36 @@
   typename enable_if<
     typename gtl_and<
       y_s_deconvolve,
- typename is_mutable_directed_line_segment_concept<
+ typename is_mutable_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
     segment_type
>::type &
   deconvolve(segment_type& segment,
- const typename directed_line_segment_point_type<segment_type>::type& b) {
- typename directed_line_segment_point_type<segment_type>::type l = low(segment), h = high(segment);
+ const typename segment_point_type<segment_type>::type& b) {
+ typename segment_point_type<segment_type>::type l = low(segment), h = high(segment);
     low(segment, deconvolve(l, b));
     high(segment, deconvolve(h, b));
     return segment;
   }
 
- struct y_s_e_dist1 : gtl_yes {};
+ struct y_s_e_dist : gtl_yes {};
 
   // distance from a point to a segment
   template <typename segment_type>
   typename enable_if<
     typename gtl_and<
- y_s_e_dist1,
- typename is_directed_line_segment_concept<
+ y_s_e_dist,
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type
>::type,
- typename directed_line_segment_distance_type<segment_type>::type
+ typename segment_distance_type<segment_type>::type
>::type
   euclidean_distance(const segment_type& segment,
- typename directed_line_segment_point_type<segment_type>::type position) {
- typedef typename directed_line_segment_distance_type<segment_type>::type Unit;
+ typename segment_point_type<segment_type>::type position) {
+ typedef typename segment_distance_type<segment_type>::type Unit;
     Unit x1 = x(low(segment));
     Unit y1 = y(low(segment));
     Unit x2 = x(high(segment));
@@ -575,18 +575,18 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_e_dist2,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
- typename directed_line_segment_distance_type<segment_type>::type
+ typename segment_distance_type<segment_type>::type
>::type
   euclidean_distance(const segment_type& segment,
                      const segment_type_2& b) {
- typename directed_line_segment_distance_type<segment_type>::type result1 =
+ typename segment_distance_type<segment_type>::type result1 =
         euclidean_distance(segment, low(b)),
     result2 = euclidean_distance(segment, high(b));
     if(result2 < result1) result1 = result2;
@@ -600,10 +600,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_e_intersects,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -620,7 +620,7 @@
         return true;
     }
     typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
+ typename segment_coordinate_type<segment_type>::type
> paf;
     typename paf::Point l, h, l2, h2;
     assign(l, low(segment));
@@ -638,10 +638,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_e_bintersect,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -662,10 +662,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_abuts1,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -685,10 +685,10 @@
   typename enable_if<
     typename gtl_and_3<
       y_s_abuts2,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -710,10 +710,10 @@
       typename is_mutable_point_concept<
         typename geometry_concept<point_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type>::type
>::type,
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<segment_type_2>::type
>::type
>::type,
@@ -725,7 +725,7 @@
                bool projected = false,
                bool round_closest = false) {
     typedef polygon_arbitrary_formation<
- typename directed_line_segment_coordinate_type<segment_type>::type
+ typename segment_coordinate_type<segment_type>::type
> paf;
     typename paf::Point pt;
     typename paf::Point l, h, l2, h2;
@@ -744,14 +744,14 @@
 
   template <class T>
   template <class T2>
- directed_line_segment_data<T>& directed_line_segment_data<T>::operator=(const T2& rvalue) {
+ segment_data<T>& segment_data<T>::operator=(const T2& rvalue) {
     assign(*this, rvalue);
     return *this;
   }
 
   template <typename T>
- struct geometry_concept<directed_line_segment_data<T> > {
- typedef directed_line_segment_concept type;
+ struct geometry_concept<segment_data<T> > {
+ typedef segment_concept type;
   };
 }
 }

Copied: sandbox/gtl/boost/polygon/segment_data.hpp (from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_data.hpp)
==============================================================================
--- /sandbox/gtl/boost/polygon/directed_line_segment_data.hpp (original)
+++ sandbox/gtl/boost/polygon/segment_data.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -5,42 +5,42 @@
   Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
   http://www.boost.org/LICENSE_1_0.txt).
 */
-#ifndef BOOST_POLYGON_DIRECTED_LINE_SEGMENT_DATA_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_DATA_HPP
+#ifndef BOOST_POLYGON_SEGMENT_DATA_HPP
+#define BOOST_POLYGON_SEGMENT_DATA_HPP
 #include "isotropy.hpp"
 #include "point_data.hpp"
 namespace boost { namespace polygon{
   template <typename T>
- class directed_line_segment_data {
+ class segment_data {
   public:
     typedef T coordinate_type;
     typedef point_data<T> point_type;
- inline directed_line_segment_data()
+ inline segment_data()
 #ifndef BOOST_POLYGON_MSVC
       :points_()
 #endif
     {}
- inline directed_line_segment_data(point_type low, point_type high)
+ inline segment_data(point_type low, point_type high)
 #ifndef BOOST_POLYGON_MSVC
       :points_()
 #endif
     {
       points_[LOW] = low; points_[HIGH] = high;
     }
- inline directed_line_segment_data(const directed_line_segment_data& that)
+ inline segment_data(const segment_data& that)
 #ifndef BOOST_POLYGON_MSVC
       :points_()
 #endif
     {
       (*this) = that;
     }
- inline directed_line_segment_data& operator=(
- const directed_line_segment_data& that) {
+ inline segment_data& operator=(
+ const segment_data& that) {
       points_[0] = that.points_[0]; points_[1] = that.points_[1];
       return *this;
     }
     template <typename T2>
- inline directed_line_segment_data& operator=(const T2& rvalue);
+ inline segment_data& operator=(const T2& rvalue);
     inline point_type get(direction_1d dir) const {
       return points_[dir.to_int()];
     }
@@ -54,23 +54,23 @@
         points_[1] = high;
         return *this;
     }
- inline bool operator==(const directed_line_segment_data& that) const {
+ inline bool operator==(const segment_data& that) const {
       return low() == that.low() && high() == that.high(); }
- inline bool operator!=(const directed_line_segment_data& that) const {
+ inline bool operator!=(const segment_data& that) const {
       return low() != that.low() || high() != that.high(); }
- inline bool operator<(const directed_line_segment_data& that) const {
+ inline bool operator<(const segment_data& that) const {
       if(points_[0] < that.points_[0]) return true;
       if(points_[0] > that.points_[0]) return false;
       if(points_[1] < that.points_[1]) return true;
       return false;
     }
- inline bool operator<=(const directed_line_segment_data& that) const {
+ inline bool operator<=(const segment_data& that) const {
       return !(that < *this);
     }
- inline bool operator>(const directed_line_segment_data& that) const {
+ inline bool operator>(const segment_data& that) const {
       return that < *this;
     }
- inline bool operator>=(const directed_line_segment_data& that) const {
+ inline bool operator>=(const segment_data& that) const {
       return !((*this) < that);
     }
   inline void set(direction_1d dir, point_type value) {

Copied: sandbox/gtl/boost/polygon/segment_set_data.hpp (from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp)
==============================================================================
--- /sandbox/gtl/boost/polygon/directed_line_segment_set_data.hpp (original)
+++ sandbox/gtl/boost/polygon/segment_set_data.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -5,23 +5,23 @@
   Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
   http://www.boost.org/LICENSE_1_0.txt).
 */
-#ifndef BOOST_POLYGON_DIRECTED_LINE_SEGMENT_SET_DATA_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_SET_DATA_HPP
+#ifndef BOOST_POLYGON_SEGMENT_SET_DATA_HPP
+#define BOOST_POLYGON_SEGMENT_SET_DATA_HPP
 
 namespace boost { namespace polygon{
   template <typename T>
- class directed_line_segment_set_data {
+ class segment_set_data {
   public:
     typedef T coordinate_type;
     typedef point_data<T> point_type;
- typedef directed_line_segment_data<T> directed_line_segment_type;
- typedef std::vector<directed_line_segment_type> value_type;
- typedef typename std::vector<directed_line_segment_type>::const_iterator iterator_type;
+ typedef segment_data<T> segment_type;
+ typedef std::vector<segment_type> value_type;
+ typedef typename std::vector<segment_type>::const_iterator iterator_type;
 
- inline directed_line_segment_set_data() : data_(), dirty_(false), unsorted_(false) {}
- inline directed_line_segment_set_data(const directed_line_segment_set_data& that):
+ inline segment_set_data() : data_(), dirty_(false), unsorted_(false) {}
+ inline segment_set_data(const segment_set_data& that):
       data_(that.data_), dirty_(that.dirty_), unsorted_(that.unsorted_) {}
- inline directed_line_segment_set_data& operator=(const directed_line_segment_set_data& that) {
+ inline segment_set_data& operator=(const segment_set_data& that) {
       if(this == &that) return *this;
       data_ = that.data_;
       dirty_ = that.dirty_;
@@ -29,24 +29,24 @@
       return *this;
     }
     template <typename T2>
- inline directed_line_segment_set_data& operator=(const T2& rvalue) {
+ inline segment_set_data& operator=(const T2& rvalue) {
       data_.clear();
       bool unsorted = !sorted(rvalue);
- bool dirty = !dirty(rvalue);
+ bool dirty = dirty(rvalue);
       insert(begin(rvalue), end(rvalue));
       unsorted_ = unsorted;
       dirty_ = dirty;
       return *this;
     }
 
- inline bool operator==(const directed_line_segment_set_data& that) const {
+ inline bool operator==(const segment_set_data& that) const {
       clean();
       that.clean();
       sort();
       that.sort();
       return data_ == that.data_;
     }
- inline bool operator!=(const directed_line_segment_set_data& that) const {
+ inline bool operator!=(const segment_set_data& that) const {
       return !(*this == that);
     }
 
@@ -62,7 +62,7 @@
     inline void insert(ST segment) {
       unsorted_ = true;
       dirty_ = true;
- directed_line_segment_type tmp_seg;
+ segment_type tmp_seg;
       assign(tmp_seg, segment);
       data_.push_back(tmp_seg);
     }
@@ -125,10 +125,10 @@
         id = half_edges_out[i].second;
         Point l = half_edges_out[i].first.first;
         Point h = half_edges_out[i].first.second;
- directed_line_segment_type orig_seg = data_[id];
+ segment_type orig_seg = data_[id];
         if(orig_seg.high() < orig_seg.low())
           std::swap(l, h);
- result.push_back(directed_line_segment_type(l, h));
+ result.push_back(segment_type(l, h));
       }
       std::swap(result, data_);
       dirty_ = false;
@@ -175,7 +175,7 @@
     }
 
     template <typename transform_type>
- inline directed_line_segment_set_data&
+ inline segment_set_data&
     transform(const transform_type& tr) {
       for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
         point_type l = (*itr).low();
@@ -189,7 +189,7 @@
       return *this;
     }
 
- inline directed_line_segment_set_data&
+ inline segment_set_data&
     scale_up(typename coordinate_traits<coordinate_type>::unsigned_area_type factor) {
       for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
         point_type l = (*itr).low();
@@ -202,7 +202,7 @@
       return *this;
     }
     
- inline directed_line_segment_set_data&
+ inline segment_set_data&
     scale_down(typename coordinate_traits<coordinate_type>::unsigned_area_type factor) {
       for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
         point_type l = (*itr).low();
@@ -216,7 +216,7 @@
     }
     
     template <typename scaling_type>
- inline directed_line_segment_set_data& scale(const scaling_type& scaling) {
+ inline segment_set_data& scale(const scaling_type& scaling) {
       for(typename value_type::iterator itr = data_.begin(); itr != data_.end(); ++itr) {
         point_type l = (*itr).low();
         point_type h = (*itr).high();
@@ -245,7 +245,8 @@
       }
       half_edges_out.reserve(half_edges.size());
       std::vector<std::set<Point> > intersection_points(half_edges.size(), std::set<Point>());
- line_intersection<Unit>::validate_scan_divide_and_conquer(intersection_points, half_edges.begin(), half_edges.end());
+ line_intersection<Unit>::validate_scan_divide_and_conquer(
+ intersection_points, half_edges.begin(), half_edges.end());
       std::vector<Point> tmp_points;
       for(std::size_t i = 0; i < intersection_points.size(); ++i) {
         typename std::set<Point>::iterator itr2 = intersection_points[i].begin();
@@ -254,7 +255,8 @@
             tmp_points.push_back(*itr2);
       }
       polygon_sort(tmp_points.begin(), tmp_points.end());
- typename std::vector<Point>::iterator new_end = std::unique(tmp_points.begin(), tmp_points.end());
+ typename std::vector<Point>::iterator new_end =
+ std::unique(tmp_points.begin(), tmp_points.end());
       output_points.insert(output_points.end(), tmp_points.begin(), new_end);
       return std::distance(tmp_points.begin(), new_end);
     }

Copied: sandbox/gtl/boost/polygon/segment_traits.hpp (from r78172, /sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp)
==============================================================================
--- /sandbox/gtl/boost/polygon/directed_line_segment_traits.hpp (original)
+++ sandbox/gtl/boost/polygon/segment_traits.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -5,11 +5,11 @@
   Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
   http://www.boost.org/LICENSE_1_0.txt).
 */
-#ifndef BOOST_POLYGON_DIRECTED_LINE_SEGMENT_TRAITS_HPP
-#define BOOST_POLYGON_DIRECTED_LINE_SEGMENT_TRAITS_HPP
+#ifndef BOOST_POLYGON_SEGMENT_TRAITS_HPP
+#define BOOST_POLYGON_SEGMENT_TRAITS_HPP
 namespace boost { namespace polygon{
   template <typename T>
- struct directed_line_segment_traits {
+ struct segment_traits {
     typedef typename T::coordinate_type coordinate_type;
     typedef typename T::point_type point_type;
 
@@ -19,10 +19,10 @@
   };
 
   template <typename T>
- struct directed_line_segment_mutable_traits {
+ struct segment_mutable_traits {
     template <typename Point1>
     static inline void set(T& segment, direction_1d dir, const Point1& value) {
- typename directed_line_segment_traits<T>::point_type p1;
+ typename segment_traits<T>::point_type p1;
       assign(p1, value);
       segment.set(dir, value);
     }
@@ -30,7 +30,7 @@
     template <typename Point1, typename Point2>
     static inline T construct(const Point1& low_value,
                               const Point2& high_value) {
- typename directed_line_segment_traits<T>::point_type p1, p2;
+ typename segment_traits<T>::point_type p1, p2;
       assign(p1, low_value);
       assign(p2, high_value);
       return T(p1, p2);

Modified: sandbox/gtl/boost/polygon/voronoi.hpp
==============================================================================
--- sandbox/gtl/boost/polygon/voronoi.hpp (original)
+++ sandbox/gtl/boost/polygon/voronoi.hpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -66,7 +66,7 @@
 static inline
 typename enable_if<
   typename gtl_if<
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
       typename geometry_concept<Segment>::type
>::type
>::type,
@@ -80,7 +80,7 @@
 static inline
 typename enable_if<
   typename gtl_if<
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
       typename geometry_concept<
         typename std::iterator_traits<SegmentIterator>::value_type
>::type
@@ -116,7 +116,7 @@
 static inline
 typename enable_if<
   typename gtl_if<
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
       typename geometry_concept<
         typename std::iterator_traits<SegmentIterator>::value_type
>::type
@@ -142,7 +142,7 @@
>::type
>::type,
     typename gtl_if<
- typename is_directed_line_segment_concept<
+ typename is_segment_concept<
         typename geometry_concept<
           typename std::iterator_traits<SegmentIterator>::value_type
>::type

Modified: sandbox/gtl/libs/polygon/benchmark/voronoi_benchmark_segments.cpp
==============================================================================
--- sandbox/gtl/libs/polygon/benchmark/voronoi_benchmark_segments.cpp (original)
+++ sandbox/gtl/libs/polygon/benchmark/voronoi_benchmark_segments.cpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -40,8 +40,8 @@
 // Include for the Boost.Polygon library.
 #include <boost/polygon/polygon.hpp>
 typedef boost::polygon::point_data<int32> POINT_POLYGON;
-typedef boost::polygon::directed_line_segment_data<int32> SEGMENT_POLYGON;
-typedef boost::polygon::directed_line_segment_set_data<int32> SSD_POLYGON;
+typedef boost::polygon::segment_data<int32> SEGMENT_POLYGON;
+typedef boost::polygon::segment_set_data<int32> SSD_POLYGON;
 
 const int RANDOM_SEED = 27;
 const int NUM_TESTS = 6;

Modified: sandbox/gtl/libs/polygon/example/voronoi_basic_tutorial.cpp
==============================================================================
--- sandbox/gtl/libs/polygon/example/voronoi_basic_tutorial.cpp (original)
+++ sandbox/gtl/libs/polygon/example/voronoi_basic_tutorial.cpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -42,10 +42,10 @@
 };
 
 template <>
-struct geometry_concept<Segment> { typedef directed_line_segment_concept type; };
+struct geometry_concept<Segment> { typedef segment_concept type; };
 
 template <>
-struct directed_line_segment_traits<Segment> {
+struct segment_traits<Segment> {
   typedef int coordinate_type;
   typedef Point point_type;
     

Modified: sandbox/gtl/libs/polygon/test/voronoi_benchmark_test.cpp
==============================================================================
--- sandbox/gtl/libs/polygon/test/voronoi_benchmark_test.cpp (original)
+++ sandbox/gtl/libs/polygon/test/voronoi_benchmark_test.cpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -117,9 +117,9 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(benchmark_test_segments, T, test_types) {
     typedef T coordinate_type;
     typedef point_data<coordinate_type> point_type;
- typedef directed_line_segment_data<coordinate_type> segment_type;
+ typedef segment_data<coordinate_type> segment_type;
 
- directed_line_segment_set_data<coordinate_type> segments;
+ segment_set_data<coordinate_type> segments;
     {
         std::ifstream input_file(SEGMENT_INPUT_FILE);
         int num_segments;

Modified: sandbox/gtl/libs/polygon/test/voronoi_builder_test.cpp
==============================================================================
--- sandbox/gtl/libs/polygon/test/voronoi_builder_test.cpp (original)
+++ sandbox/gtl/libs/polygon/test/voronoi_builder_test.cpp 2012-04-24 16:01:59 EDT (Tue, 24 Apr 2012)
@@ -374,10 +374,10 @@
 
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_sites_test1, T, test_types) {
     vd_type test_output;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(0, 0);
     point_data<T> point2(1, 1);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
     construct_voronoi(segments.begin(), segments.end(), &test_output);
     CHECK_OUTPUT_SIZE(test_output, 3, 0, 2);
     VERIFY_NO_HALF_EDGE_INTERSECTIONS(test_output);
@@ -386,12 +386,12 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_sites_test2, T, test_types) {
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(0, 0);
     point_data<T> point2(4, 4);
     point_data<T> point3(3, 1);
     point_data<T> point4(1, 3);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
     points.push_back(point3);
     points.push_back(point4);
     construct_voronoi(points.begin(), points.end(), segments.begin(), segments.end(), &test_output);
@@ -402,12 +402,12 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_sites_test3, T, test_types) {
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(4, 0);
     point_data<T> point2(0, 4);
     point_data<T> point3(3, 3);
     point_data<T> point4(1, 1);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
     points.push_back(point3);
     points.push_back(point4);
     construct_voronoi(points.begin(), points.end(), segments.begin(), segments.end(), &test_output);
@@ -418,12 +418,12 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_sites_test4, T, test_types) {
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(4, 0);
     point_data<T> point2(0, 4);
     point_data<T> point3(3, 2);
     point_data<T> point4(2, 3);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
     points.push_back(point3);
     points.push_back(point4);
     construct_voronoi(points.begin(), points.end(), segments.begin(), segments.end(), &test_output);
@@ -434,13 +434,13 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_site_test5, T, test_types) {
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(0, 0);
     point_data<T> point2(0, 8);
     point_data<T> point3(-2, -2);
     point_data<T> point4(-2, 4);
     point_data<T> point5(-2, 10);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
     points.push_back(point3);
     points.push_back(point4);
     points.push_back(point5);
@@ -452,11 +452,11 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_site_test6, T, test_types) {
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(-1, 1);
     point_data<T> point2(1, 0);
     point_data<T> point3(1, 2);
- segments.insert(directed_line_segment_data<T>(point2, point3));
+ segments.insert(segment_data<T>(point2, point3));
     points.push_back(point1);
     construct_voronoi(points.begin(), points.end(), segments.begin(), segments.end(), &test_output);
     CHECK_OUTPUT_SIZE(test_output, 4, 2, 5);
@@ -465,14 +465,14 @@
 
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_site_test7, T, test_types) {
     vd_type test_output;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(0, 0);
     point_data<T> point2(4, 0);
     point_data<T> point3(0, 4);
     point_data<T> point4(4, 4);
- segments.insert(directed_line_segment_data<T>(point1, point2));
- segments.insert(directed_line_segment_data<T>(point2, point3));
- segments.insert(directed_line_segment_data<T>(point3, point4));
+ segments.insert(segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point2, point3));
+ segments.insert(segment_data<T>(point3, point4));
     construct_voronoi(segments.begin(), segments.end(), &test_output);
     CHECK_OUTPUT_SIZE(test_output, 7, 6, 12);
     VERIFY_NO_HALF_EDGE_INTERSECTIONS(test_output);
@@ -480,15 +480,15 @@
 
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_site_test8, T, test_types) {
     vd_type test_output;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     point_data<T> point1(0, 0);
     point_data<T> point2(4, 0);
     point_data<T> point3(4, 4);
     point_data<T> point4(0, 4);
- segments.insert(directed_line_segment_data<T>(point1, point2));
- segments.insert(directed_line_segment_data<T>(point2, point3));
- segments.insert(directed_line_segment_data<T>(point3, point4));
- segments.insert(directed_line_segment_data<T>(point4, point1));
+ segments.insert(segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point2, point3));
+ segments.insert(segment_data<T>(point3, point4));
+ segments.insert(segment_data<T>(point4, point1));
     construct_voronoi(segments.begin(), segments.end(), &test_output);
     CHECK_OUTPUT_SIZE(test_output, 8, 5, 12);
     VERIFY_NO_HALF_EDGE_INTERSECTIONS(test_output);
@@ -497,7 +497,7 @@
 #ifdef NDEBUG
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_grid_test, T, test_types) {
     vd_type test_output_small, test_output_large;
- directed_line_segment_set_data<T> segments_small, segments_large;
+ segment_set_data<T> segments_small, segments_large;
     int grid_size[] = {10, 33, 100};
     int max_value[] = {100, 330, 1000};
     int array_length = sizeof(grid_size) / sizeof(int);
@@ -514,14 +514,14 @@
                 point_data<T> point1_2(koef * 10 * i, koef * 10 * j);
                 point_data<T> point2_1(10 * i, 10 * j + 10);
                 point_data<T> point2_2(koef * 10 * i, koef * (10 * j + 10));
- segments_small.insert(directed_line_segment_data<T>(point1_1, point2_1));
- segments_large.insert(directed_line_segment_data<T>(point1_2, point2_2));
+ segments_small.insert(segment_data<T>(point1_1, point2_1));
+ segments_large.insert(segment_data<T>(point1_2, point2_2));
                 point_data<T> point3_1(10 * j, 10 * i);
                 point_data<T> point3_2(koef * 10 * j, koef * 10 * i);
                 point_data<T> point4_1(10 * j + 10, 10 * i);
                 point_data<T> point4_2(koef * (10 * j + 10), koef * 10 * i);
- segments_small.insert(directed_line_segment_data<T>(point3_1, point4_1));
- segments_large.insert(directed_line_segment_data<T>(point3_2, point4_2));
+ segments_small.insert(segment_data<T>(point3_1, point4_1));
+ segments_large.insert(segment_data<T>(point3_2, point4_2));
             }
         construct_voronoi(segments_small.begin(), segments_small.end(), &test_output_small);
         construct_voronoi(segments_large.begin(), segments_large.end(), &test_output_large);
@@ -539,7 +539,7 @@
     boost::mt19937 gen(static_cast<unsigned int>(time(NULL)));
     vd_type test_output;
     std::vector< point_data<T> > points;
- directed_line_segment_set_data<T> segments;
+ segment_set_data<T> segments;
     int num_runs = 1000;
     int num_segments = 10;
     points.push_back(point_data<T>(-100, -100));
@@ -559,7 +559,7 @@
             }
             point_data<T> point1(x1, y1);
             point_data<T> point2(x2, y2);
- segments.insert(directed_line_segment_data<T>(point1, point2));
+ segments.insert(segment_data<T>(point1, point2));
         }
         segments.clean();
         construct_voronoi(points.begin(), points.end(), segments.begin(), segments.end(), &test_output);
@@ -572,7 +572,7 @@
 BOOST_AUTO_TEST_CASE_TEMPLATE(segment_random_test2, T, test_types) {
     boost::mt19937 gen(static_cast<unsigned int>(time(NULL)));
     vd_type test_output_small, test_output_large;
- directed_line_segment_set_data<T> segments_small, segments_large;
+ segment_set_data<T> segments_small, segments_large;
     int num_segments[] = {5, 25, 125, 625};
     int num_runs[] = {1000, 100, 10, 1};
     int mod_koef1[] = {10, 100, 200, 300};
@@ -598,10 +598,10 @@
                 T y2 = y1 + dy;
                 point_data<T> point1_small(x1, y1);
                 point_data<T> point2_small(x2, y2);
- segments_small.insert(directed_line_segment_data<T>(point1_small, point2_small));
+ segments_small.insert(segment_data<T>(point1_small, point2_small));
             }
             segments_small.clean();
- for (typename directed_line_segment_set_data<T>::iterator_type it = segments_small.begin();
+ for (typename segment_set_data<T>::iterator_type it = segments_small.begin();
                  it != segments_small.end(); ++it) {
                 T x1 = it->low().x() * koef;
                 T y1 = it->low().y() * koef;
@@ -609,7 +609,7 @@
                 T y2 = it->high().y() * koef;
                 point_data<T> point1_large(x1, y1);
                 point_data<T> point2_large(x2, y2);
- segments_large.insert(directed_line_segment_data<T>(point1_large, point2_large));
+ segments_large.insert(segment_data<T>(point1_large, point2_large));
             }
             construct_voronoi(segments_small.begin(), segments_small.end(), &test_output_small);
             construct_voronoi(segments_large.begin(), segments_large.end(), &test_output_large);


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk