Mesa (gallium-0.2): gallium: Add PIPE_BUFFER_USAGE_DISCARD.

Younes Manton ymanton at kemper.freedesktop.org
Mon Jan 19 02:48:32 UTC 2009


Module: Mesa
Branch: gallium-0.2
Commit: 0521c2682a3249562ff6a3d6ab6c90d1d63b82a3
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=0521c2682a3249562ff6a3d6ab6c90d1d63b82a3

Author: Younes Manton <younes.m at gmail.com>
Date:   Wed Jan 14 00:21:24 2009 -0500

gallium: Add PIPE_BUFFER_USAGE_DISCARD.

When passed to map() signals that the buffer's previous contents are
not required, allowing the driver to allocate a new buffer if the
current buffer can not be mapped immediately.

---

 src/gallium/include/pipe/p_defines.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h
index 5c6a92b..4f0b301 100644
--- a/src/gallium/include/pipe/p_defines.h
+++ b/src/gallium/include/pipe/p_defines.h
@@ -204,6 +204,7 @@ enum pipe_texture_target {
 #define PIPE_BUFFER_USAGE_VERTEX    (1 << 5)
 #define PIPE_BUFFER_USAGE_INDEX     (1 << 6)
 #define PIPE_BUFFER_USAGE_CONSTANT  (1 << 7)
+#define PIPE_BUFFER_USAGE_DISCARD   (1 << 8)
 /** Pipe driver custom usage flags should be greater or equal to this value */
 #define PIPE_BUFFER_USAGE_CUSTOM    (1 << 16)
 




More information about the mesa-commit mailing list