[cairo-commit] libglc/src glc_trap.c,1.13,1.14
David Reveman
commit at pdx.freedesktop.org
Mon Aug 15 11:12:59 PDT 2005
Committed by: davidr
Update of /cvs/cairo/libglc/src
In directory pdx:/tmp/cvs-serv16827/src
Modified Files:
glc_trap.c
Log Message:
Removed ugly trapezoid hack
Index: glc_trap.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_trap.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** a/glc_trap.c 29 Feb 2004 17:37:42 -0000 1.13
--- b/glc_trap.c 12 Mar 2004 09:44:19 -0000 1.14
***************
*** 95,133 ****
}
- glc_bool_t
- glc_composite_direct_check (glc_operator_t op,
- glc_surface_t *src,
- glc_surface_t *dst,
- int x_src,
- int y_src,
- const glc_trapezoid_t *traps)
- {
- int16_t x1, y1, x2, y2;
-
- if (!TRAPEZOID_VALID (traps))
- return 1;
-
- y1 = FIXED_TO_INT (traps->top);
-
- y2 = FIXED_TO_INT (FIXED_CEIL (traps->bottom));
-
- x1 = FIXED_TO_INT (MAX (glc_line_fixed_x (&traps->left, traps->top, 0),
- glc_line_fixed_x (&traps->left,
- traps->bottom, 0)));
- x2 = FIXED_TO_INT (FIXED_CEIL
- (MIN (glc_line_fixed_x (&traps->right, traps->top, 1),
- glc_line_fixed_x (&traps->right,
- traps->bottom, 1))));
-
- if (x1 <= 0 && x2 >= dst->width &&
- y1 <= 0 && y2 >= dst->height) {
- glc_composite (op, src, NULL, dst, x_src, y_src, 0, 0, 0, 0,
- dst->width, dst->height);
- return 1;
- }
-
- return 0;
- }
-
void
glc_composite_trapezoids (glc_operator_t op,
--- 95,98 ----
***************
*** 154,161 ****
dst->height + y_src);
- if (n_traps == 1 &&
- glc_composite_direct_check (op, src, dst, x_src, y_src, traps))
- return;
-
glc_trapezoid_bounds (n_traps, traps, &bounds);
if (bounds.y1 >= bounds.y2 || bounds.x1 >= bounds.x2 ||
--- 119,122 ----
More information about the cairo-commit
mailing list