diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2012-06-08 17:22:17 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2012-06-08 17:26:11 +0100 |
commit | fc501fd6b5c378006cd8970c1dd30ee753817b6d (patch) | |
tree | 1f75bd42bd7280411c00d6b63334f07788a9e75a | |
parent | 1bc696a8fda55ee75139f7d0123d348bbd96d2af (diff) |
tor-scan-converter: Always recompute min-height following edge removal
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r-- | src/cairo-tor-scan-converter.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/cairo-tor-scan-converter.c b/src/cairo-tor-scan-converter.c index 099b50bf..82332606 100644 --- a/src/cairo-tor-scan-converter.c +++ b/src/cairo-tor-scan-converter.c @@ -1300,6 +1300,7 @@ sub_row (struct active_list *active, pos->next = edge; } else prev_x = edge->x.quo; + active->min_height = -1; } else { edge->prev->next = next; next->prev = edge->prev; @@ -1318,12 +1319,13 @@ sub_row (struct active_list *active, } } -inline static void dec (struct edge *e, int h) +inline static void dec (struct active_list *a, struct edge *e, int h) { e->height_left -= h; if (e->height_left == 0) { e->prev->next = e->next; e->next->prev = e->prev; + a->min_height = -1; } } @@ -1350,12 +1352,12 @@ full_row (struct active_list *active, struct edge *right; int winding; - dec (left, GRID_Y); + dec (active, left, GRID_Y); winding = left->dir; right = left->next; do { - dec (right, GRID_Y); + dec (active, right, GRID_Y); winding += right->dir; if ((winding & mask) == 0 && right->next->x.quo != right->x.quo) @@ -1525,6 +1527,7 @@ step_edges (struct active_list *active, int count) if (! edge->height_left) { edge->prev->next = edge->next; edge->next->prev = edge->prev; + active->min_height = -1; } } } |