ref: b002f6882dbf184f353bee39db152a56d4b528d8
parent: 5a6dc87240905f0e55568678e0fbf93a51242051
author: Alexei Podtelezhnikov <[email protected]>
date: Mon Sep 7 09:47:36 EDT 2015
* src/smooth/ftgrays.c (gray_render_line): Simplify clipping.
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2015-09-07 Alexei Podtelezhnikov <[email protected]>
+
+ * src/smooth/ftgrays.c (gray_render_line): Simplify clipping.
+
2015-09-04 Alexei Podtelezhnikov <[email protected]>
[raster,smooth] Microoptimizations.
--- a/src/smooth/ftgrays.c
+++ b/src/smooth/ftgrays.c
@@ -805,20 +805,9 @@
dy = to_y - ras.y;
/* perform vertical clipping */
- {
- TCoord min, max;
-
-
- min = ey1;
- max = ey2;
- if ( ey1 > ey2 )
- {
- min = ey2;
- max = ey1;
- }
- if ( min >= ras.max_ey || max < ras.min_ey )
- goto End;
- }
+ if ( ( ey1 >= ras.max_ey && ey2 >= ras.max_ey ) ||
+ ( ey1 < ras.min_ey && ey2 < ras.min_ey ) )
+ goto End;
/* everything is on a single scanline */
if ( ey1 == ey2 )