mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-01-05 05:40:18 +01:00
bentley-ottman: End subsumed colinear traps
I'm not quite sure how we end up with a pair of colinear edges both with a deferred trap... Fixes crash in bug-bo-ricotz Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
0aabde2314
commit
a0ec977944
1 changed files with 9 additions and 3 deletions
|
|
@ -1434,12 +1434,18 @@ _active_edges_to_traps (cairo_bo_edge_t *pos,
|
|||
left = pos;
|
||||
while (pos != NULL) {
|
||||
if (pos != left && pos->deferred_trap.right) {
|
||||
if (edges_colinear (left, pos)) {
|
||||
/* XXX It shouldn't be possible to here with 2 deferred traps
|
||||
* on colinear edges... See bug-bo-rictoz.
|
||||
*/
|
||||
if (left->deferred_trap.right == NULL &&
|
||||
edges_colinear (left, pos))
|
||||
{
|
||||
/* continuation on left */
|
||||
assert (left->deferred_trap.right == NULL);
|
||||
left->deferred_trap = pos->deferred_trap;
|
||||
pos->deferred_trap.right = NULL;
|
||||
} else {
|
||||
}
|
||||
else
|
||||
{
|
||||
status = _cairo_bo_edge_end_trap (pos, top, traps);
|
||||
if (unlikely (status))
|
||||
return status;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue