summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/util
diff options
context:
space:
mode:
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>2009-12-20 19:09:35 +0100
committerMichal Krol <michal@vmware.com>2009-12-20 19:09:35 +0100
commita6e663def416f73ea8c0c65e8ee6a4dfaaeffae2 (patch)
treef9173198689e407f6b6da55a6fe3bdbb39d7bbd6 /src/gallium/auxiliary/util
parentb3ac75f7eb6348032c9b214d6048678aa1cc07c3 (diff)
util: util_format_get_blocksizebits() returns bits per block.
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r--src/gallium/auxiliary/util/u_format.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/auxiliary/util/u_format.h b/src/gallium/auxiliary/util/u_format.h
index c344c4201b..090183fb17 100644
--- a/src/gallium/auxiliary/util/u_format.h
+++ b/src/gallium/auxiliary/util/u_format.h
@@ -201,7 +201,7 @@ util_format_is_depth_and_stencil(enum pipe_format format)
/**
- * Return total bits needed for the pixel format.
+ * Return total bits needed for the pixel format per block.
*/
static INLINE uint
util_format_get_blocksizebits(enum pipe_format format)
@@ -213,11 +213,11 @@ util_format_get_blocksizebits(enum pipe_format format)
return 0;
}
- return desc->block.bits / (desc->block.width * desc->block.height);
+ return desc->block.bits;
}
/**
- * Return bytes per pixel for the given format.
+ * Return bytes per block (not pixel) for the given format.
*/
static INLINE uint
util_format_get_blocksize(enum pipe_format format)