summaryrefslogtreecommitdiff
path: root/src/cairo-fixed.c
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2006-02-13 16:46:47 -0800
committerCarl Worth <cworth@cworth.org>2006-02-13 16:46:47 -0800
commit0b5ac24b1522b3287903c04fb894bfae4fc67403 (patch)
treeb8256ae476f183ba07c4f4ef031d31bc31927910 /src/cairo-fixed.c
parentdb163fcc882251188e0ce63d0b9606cb59664da0 (diff)
parent90689370267f3c02d6be62e3e8c85cccdad6f577 (diff)
Remove pixman and revert tessellation bug from SNAPSHOT_0_3_0SNAPSHOT_0_3_0
Diffstat (limited to 'src/cairo-fixed.c')
-rw-r--r--src/cairo-fixed.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/cairo-fixed.c b/src/cairo-fixed.c
index 32368d7fc..ee31718ef 100644
--- a/src/cairo-fixed.c
+++ b/src/cairo-fixed.c
@@ -71,3 +71,21 @@ _cairo_fixed_integer_part (cairo_fixed_t f)
{
return f >> 16;
}
+
+int
+_cairo_fixed_integer_floor (cairo_fixed_t f)
+{
+ if (f >= 0)
+ return f >> 16;
+ else
+ return -((-f - 1) >> 16) - 1;
+}
+
+int
+_cairo_fixed_integer_ceil (cairo_fixed_t f)
+{
+ if (f >= 0)
+ return ((f - 1)>>16) + 1;
+ else
+ return - (-f >> 16);
+}