diff options
author | Ben Skeggs <skeggsb@gmail.com> | 2007-12-15 09:48:11 +1100 |
---|---|---|
committer | Ben Skeggs <skeggsb@gmail.com> | 2007-12-15 09:48:11 +1100 |
commit | b5b9ac62e6a9667de4bb2078d5cd3199fe25f619 (patch) | |
tree | 5c3f389d10132cd2c9733c5c0f3d81a657298f53 /src/mesa/pipe/p_util.h | |
parent | 7f89c776e19b400c0adf647fc9dfb392efe88dbd (diff) | |
parent | 017f862de1f857bca29f09794539aaf411014f13 (diff) |
Merge branch 'upstream-gallium-0.1' into darktama-gallium-0.1
Diffstat (limited to 'src/mesa/pipe/p_util.h')
-rw-r--r-- | src/mesa/pipe/p_util.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/pipe/p_util.h b/src/mesa/pipe/p_util.h index e6d284d932..46edcf3075 100644 --- a/src/mesa/pipe/p_util.h +++ b/src/mesa/pipe/p_util.h @@ -360,6 +360,11 @@ static INLINE float LOG2(float val) #define CEILF(x) ((float) ceil(x)) #endif +static INLINE int align(int value, int alignment) +{ + return (value + alignment - 1) & ~(alignment - 1); +} + /* Convenient... */ extern void _mesa_printf(const char *str, ...); |