summaryrefslogtreecommitdiff
path: root/src/mesa/main/mtypes.h
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2010-10-12 12:26:10 -0400
committerKristian Høgsberg <krh@bitplanet.net>2010-10-13 09:43:25 -0400
commitf9995b30756140724f41daf963fa06167912be7f (patch)
treebc34fd4db5eb9d2ad55968cb4e6e4e5a65df5a27 /src/mesa/main/mtypes.h
parent31aca27c08d6a385c595d34fe4ee06390bf5b0e8 (diff)
Drop GLcontext typedef and use struct gl_context instead
Diffstat (limited to 'src/mesa/main/mtypes.h')
-rw-r--r--src/mesa/main/mtypes.h88
1 files changed, 44 insertions, 44 deletions
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 806a19d02a..aace09d6ef 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -123,8 +123,8 @@ struct gl_program_cache;
struct gl_texture_format;
struct gl_texture_image;
struct gl_texture_object;
+struct gl_context;
struct st_context;
-typedef struct __GLcontextRec GLcontext;
/*@}*/
@@ -2324,38 +2324,38 @@ struct gl_renderbuffer
void (*Delete)(struct gl_renderbuffer *rb);
/* Allocate new storage for this renderbuffer */
- GLboolean (*AllocStorage)(GLcontext *ctx, struct gl_renderbuffer *rb,
+ GLboolean (*AllocStorage)(struct gl_context *ctx, struct gl_renderbuffer *rb,
GLenum internalFormat,
GLuint width, GLuint height);
/* Lock/Unlock are called before/after calling the Get/Put functions.
* Not sure this is the right place for these yet.
- void (*Lock)(GLcontext *ctx, struct gl_renderbuffer *rb);
- void (*Unlock)(GLcontext *ctx, struct gl_renderbuffer *rb);
+ void (*Lock)(struct gl_context *ctx, struct gl_renderbuffer *rb);
+ void (*Unlock)(struct gl_context *ctx, struct gl_renderbuffer *rb);
*/
/* Return a pointer to the element/pixel at (x,y).
* Should return NULL if the buffer memory can't be directly addressed.
*/
- void *(*GetPointer)(GLcontext *ctx, struct gl_renderbuffer *rb,
+ void *(*GetPointer)(struct gl_context *ctx, struct gl_renderbuffer *rb,
GLint x, GLint y);
/* Get/Read a row of values.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*GetRow)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*GetRow)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
GLint x, GLint y, void *values);
/* Get/Read values at arbitrary locations.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*GetValues)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*GetValues)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
const GLint x[], const GLint y[], void *values);
/* Put/Write a row of values.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*PutRow)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*PutRow)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
GLint x, GLint y, const void *values, const GLubyte *mask);
/* Put/Write a row of RGB values. This is a special-case routine that's
@@ -2363,26 +2363,26 @@ struct gl_renderbuffer
* a common case for glDrawPixels and some triangle routines.
* The values will be of format GL_RGB and type DataType.
*/
- void (*PutRowRGB)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*PutRowRGB)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
GLint x, GLint y, const void *values, const GLubyte *mask);
/* Put/Write a row of identical values.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*PutMonoRow)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*PutMonoRow)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
GLint x, GLint y, const void *value, const GLubyte *mask);
/* Put/Write values at arbitrary locations.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*PutValues)(GLcontext *ctx, struct gl_renderbuffer *rb, GLuint count,
+ void (*PutValues)(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count,
const GLint x[], const GLint y[], const void *values,
const GLubyte *mask);
/* Put/Write identical values at arbitrary locations.
* The values will be of format _BaseFormat and type DataType.
*/
- void (*PutMonoValues)(GLcontext *ctx, struct gl_renderbuffer *rb,
+ void (*PutMonoValues)(struct gl_context *ctx, struct gl_renderbuffer *rb,
GLuint count, const GLint x[], const GLint y[],
const void *value, const GLubyte *mask);
};
@@ -2787,7 +2787,7 @@ struct gl_matrix_stack
/**
* \name Bits for image transfer operations
- * \sa __GLcontextRec::ImageTransferState.
+ * \sa __struct gl_contextRec::ImageTransferState.
*/
/*@{*/
#define IMAGE_SCALE_BIAS_BIT 0x1
@@ -2807,34 +2807,34 @@ struct gl_matrix_stack
* 4 unused flags.
*/
/*@{*/
-#define _NEW_MODELVIEW 0x1 /**< __GLcontextRec::ModelView */
-#define _NEW_PROJECTION 0x2 /**< __GLcontextRec::Projection */
-#define _NEW_TEXTURE_MATRIX 0x4 /**< __GLcontextRec::TextureMatrix */
-#define _NEW_ACCUM 0x10 /**< __GLcontextRec::Accum */
-#define _NEW_COLOR 0x20 /**< __GLcontextRec::Color */
-#define _NEW_DEPTH 0x40 /**< __GLcontextRec::Depth */
-#define _NEW_EVAL 0x80 /**< __GLcontextRec::Eval, __GLcontextRec::EvalMap */
-#define _NEW_FOG 0x100 /**< __GLcontextRec::Fog */
-#define _NEW_HINT 0x200 /**< __GLcontextRec::Hint */
-#define _NEW_LIGHT 0x400 /**< __GLcontextRec::Light */
-#define _NEW_LINE 0x800 /**< __GLcontextRec::Line */
-#define _NEW_PIXEL 0x1000 /**< __GLcontextRec::Pixel */
-#define _NEW_POINT 0x2000 /**< __GLcontextRec::Point */
-#define _NEW_POLYGON 0x4000 /**< __GLcontextRec::Polygon */
-#define _NEW_POLYGONSTIPPLE 0x8000 /**< __GLcontextRec::PolygonStipple */
-#define _NEW_SCISSOR 0x10000 /**< __GLcontextRec::Scissor */
-#define _NEW_STENCIL 0x20000 /**< __GLcontextRec::Stencil */
-#define _NEW_TEXTURE 0x40000 /**< __GLcontextRec::Texture */
-#define _NEW_TRANSFORM 0x80000 /**< __GLcontextRec::Transform */
-#define _NEW_VIEWPORT 0x100000 /**< __GLcontextRec::Viewport */
-#define _NEW_PACKUNPACK 0x200000 /**< __GLcontextRec::Pack, __GLcontextRec::Unpack */
-#define _NEW_ARRAY 0x400000 /**< __GLcontextRec::Array */
-#define _NEW_RENDERMODE 0x800000 /**< __GLcontextRec::RenderMode, __GLcontextRec::Feedback, __GLcontextRec::Select */
-#define _NEW_BUFFERS 0x1000000 /**< __GLcontextRec::Visual, __GLcontextRec::DrawBuffer, */
-#define _NEW_MULTISAMPLE 0x2000000 /**< __GLcontextRec::Multisample */
-#define _NEW_TRACK_MATRIX 0x4000000 /**< __GLcontextRec::VertexProgram */
-#define _NEW_PROGRAM 0x8000000 /**< __GLcontextRec::VertexProgram */
-#define _NEW_CURRENT_ATTRIB 0x10000000 /**< __GLcontextRec::Current */
+#define _NEW_MODELVIEW 0x1 /**< __struct gl_contextRec::ModelView */
+#define _NEW_PROJECTION 0x2 /**< __struct gl_contextRec::Projection */
+#define _NEW_TEXTURE_MATRIX 0x4 /**< __struct gl_contextRec::TextureMatrix */
+#define _NEW_ACCUM 0x10 /**< __struct gl_contextRec::Accum */
+#define _NEW_COLOR 0x20 /**< __struct gl_contextRec::Color */
+#define _NEW_DEPTH 0x40 /**< __struct gl_contextRec::Depth */
+#define _NEW_EVAL 0x80 /**< __struct gl_contextRec::Eval, __struct gl_contextRec::EvalMap */
+#define _NEW_FOG 0x100 /**< __struct gl_contextRec::Fog */
+#define _NEW_HINT 0x200 /**< __struct gl_contextRec::Hint */
+#define _NEW_LIGHT 0x400 /**< __struct gl_contextRec::Light */
+#define _NEW_LINE 0x800 /**< __struct gl_contextRec::Line */
+#define _NEW_PIXEL 0x1000 /**< __struct gl_contextRec::Pixel */
+#define _NEW_POINT 0x2000 /**< __struct gl_contextRec::Point */
+#define _NEW_POLYGON 0x4000 /**< __struct gl_contextRec::Polygon */
+#define _NEW_POLYGONSTIPPLE 0x8000 /**< __struct gl_contextRec::PolygonStipple */
+#define _NEW_SCISSOR 0x10000 /**< __struct gl_contextRec::Scissor */
+#define _NEW_STENCIL 0x20000 /**< __struct gl_contextRec::Stencil */
+#define _NEW_TEXTURE 0x40000 /**< __struct gl_contextRec::Texture */
+#define _NEW_TRANSFORM 0x80000 /**< __struct gl_contextRec::Transform */
+#define _NEW_VIEWPORT 0x100000 /**< __struct gl_contextRec::Viewport */
+#define _NEW_PACKUNPACK 0x200000 /**< __struct gl_contextRec::Pack, __struct gl_contextRec::Unpack */
+#define _NEW_ARRAY 0x400000 /**< __struct gl_contextRec::Array */
+#define _NEW_RENDERMODE 0x800000 /**< __struct gl_contextRec::RenderMode, __struct gl_contextRec::Feedback, __struct gl_contextRec::Select */
+#define _NEW_BUFFERS 0x1000000 /**< __struct gl_contextRec::Visual, __struct gl_contextRec::DrawBuffer, */
+#define _NEW_MULTISAMPLE 0x2000000 /**< __struct gl_contextRec::Multisample */
+#define _NEW_TRACK_MATRIX 0x4000000 /**< __struct gl_contextRec::VertexProgram */
+#define _NEW_PROGRAM 0x8000000 /**< __struct gl_contextRec::VertexProgram */
+#define _NEW_CURRENT_ATTRIB 0x10000000 /**< __struct gl_contextRec::Current */
#define _NEW_PROGRAM_CONSTANTS 0x20000000
#define _NEW_BUFFER_OBJECT 0x40000000
#define _NEW_ALL ~0
@@ -2877,7 +2877,7 @@ struct gl_matrix_stack
/**
* \name A bunch of flags that we think might be useful to drivers.
*
- * Set in the __GLcontextRec::_TriangleCaps bitfield.
+ * Set in the __struct gl_contextRec::_TriangleCaps bitfield.
*/
/*@{*/
#define DD_FLATSHADE 0x1
@@ -3045,9 +3045,9 @@ typedef enum {
* Think of this as a base class from which device drivers will derive
* sub classes.
*
- * The GLcontext typedef names this structure.
+ * The struct gl_context typedef names this structure.
*/
-struct __GLcontextRec
+struct gl_context
{
/** State possibly shared with other contexts in the address space */
struct gl_shared_state *Shared;