Merge branch 'develop' of github.com:boostorg/geometry into develop

This commit is contained in:
Adam Wulkiewicz
2014-08-10 16:21:00 +02:00
3 changed files with 12 additions and 8 deletions

View File

@@ -339,10 +339,12 @@ struct buffered_piece_collection
for (typename boost::range_iterator<turn_vector_type>::type it =
boost::begin(m_turns); it != boost::end(m_turns); ++it)
{
if ( it->count_within > 0
|| it->count_on_occupied > 0 )
if (it->count_within > 0)
{
it->location = inside_buffer;
// Within can have in rare cases a rounding issue. We don't discard this
// point, so it can be used to continue started rings in traversal. But
// will never start a new ring from this type of points.
it->selectable_start = false;
}
}
}
@@ -550,7 +552,7 @@ struct buffered_piece_collection
}
get_occupation();
//get_occupation();
classify_turns();

View File

@@ -322,9 +322,7 @@ void test_all()
test_one<multi_polygon_type, polygon_type>("rt_p14", rt_p14, join_miter, end_flat, 20.8284, 1.0);
test_one<multi_polygon_type, polygon_type>("rt_p15", rt_p15, join_miter, end_flat, 23.6569, 1.0);
test_one<multi_polygon_type, polygon_type>("rt_p16", rt_p16, join_miter, end_flat, 23.4853, 1.0);
#if defined(BOOST_GEOMETRY_BUFFER_INCLUDE_FAILING_TESTS)
test_one<multi_polygon_type, polygon_type>("rt_p17", rt_p17, join_miter, end_flat, 25.3137, 1.0);
#endif
test_one<multi_polygon_type, polygon_type>("rt_p18", rt_p18, join_miter, end_flat, 23.3137, 1.0);
test_one<multi_polygon_type, polygon_type>("rt_p19", rt_p19, join_miter, end_flat, 25.5637, 1.0);
test_one<multi_polygon_type, polygon_type>("rt_p20", rt_p20, join_miter, end_flat, 25.4853, 1.0);

View File

@@ -118,9 +118,13 @@ struct svg_visitor
std::string fill = "fill:rgb(0,255,0);";
switch(it->location)
{
case bgdb::inside_buffer : fill = "fill:rgb(255,0,0);"; color = 'r'; break;
case bgdb::inside_buffer : fill = "fill:rgb(255,0,0);"; color = 'r'; break; // does not happen anymore
case bgdb::inside_original : fill = "fill:rgb(0,0,255);"; color = 'b'; break;
}
if (!it->selectable_start)
{
fill = "fill:rgb(255,192,0);"; color = 'o'; // orange
}
if (it->blocked())
{
fill = "fill:rgb(128,128,128);"; color = '-';
@@ -134,7 +138,7 @@ struct svg_visitor
out << " " << bg::method_char(it->method)
<< ":" << bg::operation_char(it->operations[0].operation)
<< "/" << bg::operation_char(it->operations[1].operation);
out << " " << (it->count_within > 0 ? "w" : "")
out << " " << (!it->selectable_start ? "w" : "")
<< (it->count_on_multi > 0 ? "m" : "")
<< (it->count_on_occupied > 0 ? "o" : "")
<< (it->count_on_offsetted > 0 ? "b" : "") // b: offsetted border