| 2509 | } |
| 2510 | |
| 2511 | bool ClipperBase::ResetHorzDirection(const Active& horz, |
| 2512 | const Vertex* max_vertex, int64_t& horz_left, int64_t& horz_right) |
| 2513 | { |
| 2514 | if (horz.bot.x == horz.top.x) |
| 2515 | { |
| 2516 | //the horizontal edge is going nowhere ... |
| 2517 | horz_left = horz.curr_x; |
| 2518 | horz_right = horz.curr_x; |
| 2519 | Active* e = horz.next_in_ael; |
| 2520 | while (e && e->vertex_top != max_vertex) e = e->next_in_ael; |
| 2521 | return e != nullptr; |
| 2522 | } |
| 2523 | else if (horz.curr_x < horz.top.x) |
| 2524 | { |
| 2525 | horz_left = horz.curr_x; |
| 2526 | horz_right = horz.top.x; |
| 2527 | return true; |
| 2528 | } |
| 2529 | else |
| 2530 | { |
| 2531 | horz_left = horz.top.x; |
| 2532 | horz_right = horz.curr_x; |
| 2533 | return false; // right to left |
| 2534 | } |
| 2535 | } |
| 2536 | |
| 2537 | void ClipperBase::DoHorizontal(Active& horz) |
| 2538 | /******************************************************************************* |
nothing calls this directly
no outgoing calls
no test coverage detected