diff options
author | Søren Sandmann Pedersen <soren.sandmann@gmail.com> | 2014-09-19 21:51:56 -0700 |
---|---|---|
committer | Søren Sandmann Pedersen <soren.sandmann@gmail.com> | 2014-09-19 21:56:45 -0700 |
commit | 040257ff41670c13020a78248d27da01913742dd (patch) | |
tree | 4891f0e78bf72f0d292f65a7c4e4de3158178fbc | |
parent | 6d2cf40166d81bfc63108504c8022dc4fec37ff5 (diff) |
Fix comment about BILINEAR_INTERPOLATION_BITS to say < 8 rather than <= 8for-master
Since a4c79d695d52c94647b1aff7 the constant
BILINEAR_INTERPOLATION_BITS must be strictly less than 8, so fix the
comment to say this, and also add a COMPILE_TIME_ASSERT in the
bilinear fetcher in pixman-fast-path.c
-rw-r--r-- | pixman/pixman-fast-path.c | 2 | ||||
-rw-r--r-- | pixman/pixman-private.h | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/pixman/pixman-fast-path.c b/pixman/pixman-fast-path.c index c6e43de1..53d4a1f9 100644 --- a/pixman/pixman-fast-path.c +++ b/pixman/pixman-fast-path.c @@ -2343,6 +2343,8 @@ fast_fetch_bilinear_cover (pixman_iter_t *iter, const uint32_t *mask) int32_t dist_y; int i; + COMPILE_TIME_ASSERT (BILINEAR_INTERPOLATION_BITS < 8); + fx = info->x; ux = iter->image->common.transform->matrix[0][0]; diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h index fdc966ae..73108a01 100644 --- a/pixman/pixman-private.h +++ b/pixman/pixman-private.h @@ -7,7 +7,7 @@ * The defines which are shared between C and assembly code */ -/* bilinear interpolation precision (must be <= 8) */ +/* bilinear interpolation precision (must be < 8) */ #define BILINEAR_INTERPOLATION_BITS 7 #define BILINEAR_INTERPOLATION_RANGE (1 << BILINEAR_INTERPOLATION_BITS) |