summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_context.h
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2011-09-17 14:50:48 -0600
committerBrian Paul <brianp@vmware.com>2011-09-17 14:57:40 -0600
commit1da896803cdd09293c7bb0048a2116e237a51766 (patch)
tree223384979681f6cbe2aaecb0ef631b1970bfd4ed /src/mesa/swrast/s_context.h
parent146f536b3332b7a2022bb4ba5e2d1d2ec4bedd98 (diff)
downloadexternal_mesa3d-1da896803cdd09293c7bb0048a2116e237a51766.zip
external_mesa3d-1da896803cdd09293c7bb0048a2116e237a51766.tar.gz
external_mesa3d-1da896803cdd09293c7bb0048a2116e237a51766.tar.bz2
swrast: introduce new swrast_texture_image struct
No subclass fields yet. Subsequent patches will add the fields related to software rendering that are currently in gl_texture_image.
Diffstat (limited to 'src/mesa/swrast/s_context.h')
-rw-r--r--src/mesa/swrast/s_context.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/mesa/swrast/s_context.h b/src/mesa/swrast/s_context.h
index 8d7458c..687480e 100644
--- a/src/mesa/swrast/s_context.h
+++ b/src/mesa/swrast/s_context.h
@@ -110,6 +110,35 @@ typedef void (*validate_texture_image_func)(struct gl_context *ctx,
/**
+ * Subclass of gl_texture_image.
+ * We need extra fields/info to keep tracking of mapped texture buffers,
+ * strides and Fetch/Store functions.
+ */
+struct swrast_texture_image
+{
+ struct gl_texture_image Base;
+
+ /* XXX new members coming soon */
+};
+
+
+/** cast wrapper */
+static INLINE struct swrast_texture_image *
+swrast_texture_image(struct gl_texture_image *img)
+{
+ return (struct swrast_texture_image *) img;
+}
+
+/** cast wrapper */
+static INLINE const struct swrast_texture_image *
+swrast_texture_image_const(const struct gl_texture_image *img)
+{
+ return (const struct swrast_texture_image *) img;
+}
+
+
+
+/**
* \struct SWcontext
* \brief Per-context state that's private to the software rasterizer module.
*/