aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/r600
diff options
context:
space:
mode:
authorKristian Høgsberg <[email protected]>2010-10-12 12:26:10 -0400
committerKristian Høgsberg <[email protected]>2010-10-13 09:43:25 -0400
commitf9995b30756140724f41daf963fa06167912be7f (patch)
treebc34fd4db5eb9d2ad55968cb4e6e4e5a65df5a27 /src/mesa/drivers/dri/r600
parent31aca27c08d6a385c595d34fe4ee06390bf5b0e8 (diff)
Drop GLcontext typedef and use struct gl_context instead
Diffstat (limited to 'src/mesa/drivers/dri/r600')
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_blit.c4
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_blit.h2
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_chip.c38
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_context.c2
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_fragprog.c16
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_fragprog.h16
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_ioctl.c2
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_ioctl.h2
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_oglprog.c10
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_render.c26
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_state.c94
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_state.h12
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_tex.c14
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_tex.h4
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_vertprog.c20
-rw-r--r--src/mesa/drivers/dri/r600/evergreen_vertprog.h18
-rw-r--r--src/mesa/drivers/dri/r600/r600_blit.c4
-rw-r--r--src/mesa/drivers/dri/r600/r600_blit.h2
-rw-r--r--src/mesa/drivers/dri/r600/r600_context.c8
-rw-r--r--src/mesa/drivers/dri/r600/r600_context.h6
-rw-r--r--src/mesa/drivers/dri/r600/r600_emit.c8
-rw-r--r--src/mesa/drivers/dri/r600/r600_emit.h8
-rw-r--r--src/mesa/drivers/dri/r600/r600_tex.c6
-rw-r--r--src/mesa/drivers/dri/r600/r600_tex.h2
-rw-r--r--src/mesa/drivers/dri/r600/r600_texstate.c10
-rw-r--r--src/mesa/drivers/dri/r600/r700_chip.c82
-rw-r--r--src/mesa/drivers/dri/r600/r700_clear.c2
-rw-r--r--src/mesa/drivers/dri/r600/r700_clear.h2
-rw-r--r--src/mesa/drivers/dri/r600/r700_fragprog.c14
-rw-r--r--src/mesa/drivers/dri/r600/r700_fragprog.h14
-rw-r--r--src/mesa/drivers/dri/r600/r700_oglprog.c10
-rw-r--r--src/mesa/drivers/dri/r600/r700_render.c26
-rw-r--r--src/mesa/drivers/dri/r600/r700_shader.c2
-rw-r--r--src/mesa/drivers/dri/r600/r700_shader.h2
-rw-r--r--src/mesa/drivers/dri/r600/r700_state.c104
-rw-r--r--src/mesa/drivers/dri/r600/r700_state.h10
-rw-r--r--src/mesa/drivers/dri/r600/r700_vertprog.c18
-rw-r--r--src/mesa/drivers/dri/r600/r700_vertprog.h16
38 files changed, 318 insertions, 318 deletions
diff --git a/src/mesa/drivers/dri/r600/evergreen_blit.c b/src/mesa/drivers/dri/r600/evergreen_blit.c
index 1ed8a08b78c..fc9fa9d22c7 100644
--- a/src/mesa/drivers/dri/r600/evergreen_blit.c
+++ b/src/mesa/drivers/dri/r600/evergreen_blit.c
@@ -423,7 +423,7 @@ eg_set_render_target(context_t *context, struct radeon_bo *bo, gl_format mesa_fo
}
-static inline void eg_load_shaders(GLcontext * ctx)
+static inline void eg_load_shaders(struct gl_context * ctx)
{
radeonContextPtr radeonctx = RADEON_CONTEXT(ctx);
@@ -1688,7 +1688,7 @@ static GLboolean eg_validate_buffers(context_t *rmesa,
return GL_TRUE;
}
-unsigned evergreen_blit(GLcontext *ctx,
+unsigned evergreen_blit(struct gl_context *ctx,
struct radeon_bo *src_bo,
intptr_t src_offset,
gl_format src_mesaformat,
diff --git a/src/mesa/drivers/dri/r600/evergreen_blit.h b/src/mesa/drivers/dri/r600/evergreen_blit.h
index 68d072ecb00..783f83f0899 100644
--- a/src/mesa/drivers/dri/r600/evergreen_blit.h
+++ b/src/mesa/drivers/dri/r600/evergreen_blit.h
@@ -30,7 +30,7 @@
unsigned evergreen_check_blit(gl_format mesa_format);
-unsigned evergreen_blit(GLcontext *ctx,
+unsigned evergreen_blit(struct gl_context *ctx,
struct radeon_bo *src_bo,
intptr_t src_offset,
gl_format src_mesaformat,
diff --git a/src/mesa/drivers/dri/r600/evergreen_chip.c b/src/mesa/drivers/dri/r600/evergreen_chip.c
index 770e7f91c6a..2c9e4e2b844 100644
--- a/src/mesa/drivers/dri/r600/evergreen_chip.c
+++ b/src/mesa/drivers/dri/r600/evergreen_chip.c
@@ -60,7 +60,7 @@ do { \
insert_at_tail(&context->radeon.hw.atomlist, &context->evergreen_atoms.ATOM); \
} while (0)
-static int check_queryobj(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_queryobj(struct gl_context *ctx, struct radeon_state_atom *atom)
{
radeonContextPtr radeon = RADEON_CONTEXT(ctx);
struct radeon_query_object *query = radeon->query.current;
@@ -74,7 +74,7 @@ static int check_queryobj(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static void evergreenSendQueryBegin(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendQueryBegin(struct gl_context *ctx, struct radeon_state_atom *atom)
{
radeonContextPtr radeon = RADEON_CONTEXT(ctx);
struct radeon_query_object *query = radeon->query.current;
@@ -114,12 +114,12 @@ static void evergreen_init_query_stateobj(radeonContextPtr radeon, int SZ)
}
-static int check_always(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_always(struct gl_context *ctx, struct radeon_state_atom *atom)
{
return atom->cmd_size;
}
-static void evergreenSendTexState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendTexState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -221,7 +221,7 @@ static void evergreenSendTexState(GLcontext *ctx, struct radeon_state_atom *atom
}
}
-static int check_evergreen_tx(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_evergreen_tx(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
unsigned int i, count = 0;
@@ -238,7 +238,7 @@ static int check_evergreen_tx(GLcontext *ctx, struct radeon_state_atom *atom)
return count * 37 + 6;
}
-static void evergreenSendSQConfig(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendSQConfig(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -269,7 +269,7 @@ static void evergreenSendSQConfig(GLcontext *ctx, struct radeon_state_atom *atom
}
extern int evergreen_getTypeSize(GLenum type);
-static void evergreenSetupVTXConstants(GLcontext * ctx,
+static void evergreenSetupVTXConstants(struct gl_context * ctx,
void * pAos,
StreamDesc * pStreamDesc)
{
@@ -357,7 +357,7 @@ static void evergreenSetupVTXConstants(GLcontext * ctx,
COMMIT_BATCH();
}
-static int check_evergreen_vtx(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_evergreen_vtx(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
int count = context->radeon.tcl.aos_count * 12;
@@ -369,7 +369,7 @@ static int check_evergreen_vtx(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static void evergreenSendVTX(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendVTX(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_vertex_program *vp = (struct evergreen_vertex_program *)(context->selected_vp);
@@ -390,7 +390,7 @@ static void evergreenSendVTX(GLcontext *ctx, struct radeon_state_atom *atom)
}
}
}
-static void evergreenSendPA(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendPA(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -511,7 +511,7 @@ static void evergreenSendPA(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void evergreenSendTP(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendTP(struct gl_context *ctx, struct radeon_state_atom *atom)
{
/*
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -523,7 +523,7 @@ static void evergreenSendTP(GLcontext *ctx, struct radeon_state_atom *atom)
*/
}
-static void evergreenSendPSresource(GLcontext *ctx)
+static void evergreenSendPSresource(struct gl_context *ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -578,7 +578,7 @@ static void evergreenSendPSresource(GLcontext *ctx)
COMMIT_BATCH();
}
-static void evergreenSendVSresource(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendVSresource(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -634,7 +634,7 @@ static void evergreenSendVSresource(GLcontext *ctx, struct radeon_state_atom *at
COMMIT_BATCH();
}
-static void evergreenSendSQ(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendSQ(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -749,7 +749,7 @@ static void evergreenSendSQ(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void evergreenSendSPI(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendSPI(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -821,7 +821,7 @@ static void evergreenSendSPI(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void evergreenSendSX(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendSX(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -897,7 +897,7 @@ static void evergreenSetDepthTarget(context_t *context)
}
-static void evergreenSendDB(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendDB(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1366,7 +1366,7 @@ static void evergreenSetRenderTarget(context_t *context, int id)
evergreen->render_target[id].enabled = GL_TRUE;
}
-static void evergreenSendCB(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendCB(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1451,7 +1451,7 @@ static void evergreenSendCB(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void evergreenSendVGT(GLcontext *ctx, struct radeon_state_atom *atom)
+static void evergreenSendVGT(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
diff --git a/src/mesa/drivers/dri/r600/evergreen_context.c b/src/mesa/drivers/dri/r600/evergreen_context.c
index fff7c200310..911775f590f 100644
--- a/src/mesa/drivers/dri/r600/evergreen_context.c
+++ b/src/mesa/drivers/dri/r600/evergreen_context.c
@@ -61,7 +61,7 @@ static void evergreen_vtbl_pre_emit_atoms(radeonContextPtr radeon)
r700Start3D((context_t *)radeon);
}
-static void evergreen_fallback(GLcontext *ctx, GLuint bit, GLboolean mode)
+static void evergreen_fallback(struct gl_context *ctx, GLuint bit, GLboolean mode)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
if (mode)
diff --git a/src/mesa/drivers/dri/r600/evergreen_fragprog.c b/src/mesa/drivers/dri/r600/evergreen_fragprog.c
index 0e7edf4fbe4..cfb923efdd5 100644
--- a/src/mesa/drivers/dri/r600/evergreen_fragprog.c
+++ b/src/mesa/drivers/dri/r600/evergreen_fragprog.c
@@ -44,7 +44,7 @@
#include "evergreen_vertprog.h"
#include "evergreen_fragprog.h"
-void evergreen_insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fprog)
+void evergreen_insert_wpos_code(struct gl_context *ctx, struct gl_fragment_program *fprog)
{
static const gl_state_index winstate[STATE_LENGTH]
= { STATE_INTERNAL, STATE_FB_SIZE, 0, 0, 0};
@@ -95,7 +95,7 @@ void evergreen_insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fpro
//TODO : Validate FP input with VP output.
void evergreen_Map_Fragment_Program(r700_AssemblerBase *pAsm,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx)
+ struct gl_context *ctx)
{
unsigned int unBit;
unsigned int i;
@@ -354,7 +354,7 @@ GLboolean evergreen_Find_Instruction_Dependencies_fp(struct evergreen_fragment_p
GLboolean evergreenTranslateFragmentShader(struct evergreen_fragment_program *fp,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx)
+ struct gl_context *ctx)
{
GLuint number_of_colors_exported;
GLboolean z_enabled = GL_FALSE;
@@ -457,7 +457,7 @@ GLboolean evergreenTranslateFragmentShader(struct evergreen_fragment_program *fp
return GL_TRUE;
}
-void evergreenSelectFragmentShader(GLcontext *ctx)
+void evergreenSelectFragmentShader(struct gl_context *ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_fragment_program *fp = (struct evergreen_fragment_program *)
@@ -471,7 +471,7 @@ void evergreenSelectFragmentShader(GLcontext *ctx)
evergreenTranslateFragmentShader(fp, &(fp->mesa_program), ctx);
}
-void * evergreenGetActiveFpShaderBo(GLcontext * ctx)
+void * evergreenGetActiveFpShaderBo(struct gl_context * ctx)
{
struct evergreen_fragment_program *fp = (struct evergreen_fragment_program *)
(ctx->FragmentProgram._Current);
@@ -479,7 +479,7 @@ void * evergreenGetActiveFpShaderBo(GLcontext * ctx)
return fp->shaderbo;
}
-void * evergreenGetActiveFpShaderConstBo(GLcontext * ctx)
+void * evergreenGetActiveFpShaderConstBo(struct gl_context * ctx)
{
struct evergreen_fragment_program *fp = (struct evergreen_fragment_program *)
(ctx->FragmentProgram._Current);
@@ -487,7 +487,7 @@ void * evergreenGetActiveFpShaderConstBo(GLcontext * ctx)
return fp->constbo0;
}
-GLboolean evergreenSetupFragmentProgram(GLcontext * ctx)
+GLboolean evergreenSetupFragmentProgram(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -737,7 +737,7 @@ GLboolean evergreenSetupFragmentProgram(GLcontext * ctx)
return GL_TRUE;
}
-GLboolean evergreenSetupFPconstants(GLcontext * ctx)
+GLboolean evergreenSetupFPconstants(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
diff --git a/src/mesa/drivers/dri/r600/evergreen_fragprog.h b/src/mesa/drivers/dri/r600/evergreen_fragprog.h
index 0e200bf3833..97f06a75fc0 100644
--- a/src/mesa/drivers/dri/r600/evergreen_fragprog.h
+++ b/src/mesa/drivers/dri/r600/evergreen_fragprog.h
@@ -51,27 +51,27 @@ struct evergreen_fragment_program
};
/* Internal */
-void evergreen_insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fprog);
+void evergreen_insert_wpos_code(struct gl_context *ctx, struct gl_fragment_program *fprog);
void evergreen_Map_Fragment_Program(r700_AssemblerBase *pAsm,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx);
+ struct gl_context *ctx);
GLboolean evergreen_Find_Instruction_Dependencies_fp(struct evergreen_fragment_program *fp,
struct gl_fragment_program *mesa_fp);
GLboolean evergreenTranslateFragmentShader(struct evergreen_fragment_program *fp,
struct gl_fragment_program *mesa_vp,
- GLcontext *ctx);
+ struct gl_context *ctx);
/* Interface */
-extern void evergreenSelectFragmentShader(GLcontext *ctx);
+extern void evergreenSelectFragmentShader(struct gl_context *ctx);
-extern GLboolean evergreenSetupFragmentProgram(GLcontext * ctx);
+extern GLboolean evergreenSetupFragmentProgram(struct gl_context * ctx);
-extern GLboolean evergreenSetupFPconstants(GLcontext * ctx);
+extern GLboolean evergreenSetupFPconstants(struct gl_context * ctx);
-extern void * evergreenGetActiveFpShaderBo(GLcontext * ctx);
+extern void * evergreenGetActiveFpShaderBo(struct gl_context * ctx);
-extern void * evergreenGetActiveFpShaderConstBo(GLcontext * ctx);
+extern void * evergreenGetActiveFpShaderConstBo(struct gl_context * ctx);
#endif /*_EVERGREEN_FRAGPROG_H_*/
diff --git a/src/mesa/drivers/dri/r600/evergreen_ioctl.c b/src/mesa/drivers/dri/r600/evergreen_ioctl.c
index 5c1270790df..19f8e6b3ec3 100644
--- a/src/mesa/drivers/dri/r600/evergreen_ioctl.c
+++ b/src/mesa/drivers/dri/r600/evergreen_ioctl.c
@@ -40,7 +40,7 @@
#include "r700_clear.h"
-void evergreenClear(GLcontext * ctx, GLbitfield mask)
+void evergreenClear(struct gl_context * ctx, GLbitfield mask)
{
r700Clear(ctx, mask);
}
diff --git a/src/mesa/drivers/dri/r600/evergreen_ioctl.h b/src/mesa/drivers/dri/r600/evergreen_ioctl.h
index 3c663a7083a..a41b5b60333 100644
--- a/src/mesa/drivers/dri/r600/evergreen_ioctl.h
+++ b/src/mesa/drivers/dri/r600/evergreen_ioctl.h
@@ -30,7 +30,7 @@
#include "r600_context.h"
#include "radeon_drm.h"
-extern void evergreenClear(GLcontext * ctx, GLbitfield mask);
+extern void evergreenClear(struct gl_context * ctx, GLbitfield mask);
extern void evergreenInitIoctlFuncs(struct dd_function_table *functions);
#endif /* _EVERGREEN_IOCTL_H_ */
diff --git a/src/mesa/drivers/dri/r600/evergreen_oglprog.c b/src/mesa/drivers/dri/r600/evergreen_oglprog.c
index 9fe523234cc..a2a361f32e6 100644
--- a/src/mesa/drivers/dri/r600/evergreen_oglprog.c
+++ b/src/mesa/drivers/dri/r600/evergreen_oglprog.c
@@ -40,7 +40,7 @@
#include "evergreen_vertprog.h"
-static void evergreen_freeVertProgCache(GLcontext *ctx, struct r700_vertex_program_cont *cache)
+static void evergreen_freeVertProgCache(struct gl_context *ctx, struct r700_vertex_program_cont *cache)
{
struct evergreen_vertex_program *tmp, *vp = cache->progs;
@@ -64,7 +64,7 @@ static void evergreen_freeVertProgCache(GLcontext *ctx, struct r700_vertex_progr
}
}
-static struct gl_program *evergreenNewProgram(GLcontext * ctx,
+static struct gl_program *evergreenNewProgram(struct gl_context * ctx,
GLenum target,
GLuint id)
{
@@ -109,7 +109,7 @@ static struct gl_program *evergreenNewProgram(GLcontext * ctx,
return pProgram;
}
-static void evergreenDeleteProgram(GLcontext * ctx, struct gl_program *prog)
+static void evergreenDeleteProgram(struct gl_context * ctx, struct gl_program *prog)
{
struct evergreen_vertex_program_cont *vpc = (struct evergreen_vertex_program_cont *)prog;
struct evergreen_fragment_program * fp;
@@ -147,7 +147,7 @@ static void evergreenDeleteProgram(GLcontext * ctx, struct gl_program *prog)
}
static GLboolean
-evergreenProgramStringNotify(GLcontext * ctx, GLenum target, struct gl_program *prog)
+evergreenProgramStringNotify(struct gl_context * ctx, GLenum target, struct gl_program *prog)
{
struct evergreen_vertex_program_cont *vpc = (struct evergreen_vertex_program_cont *)prog;
struct evergreen_fragment_program * fp = (struct evergreen_fragment_program*)prog;
@@ -178,7 +178,7 @@ evergreenProgramStringNotify(GLcontext * ctx, GLenum target, struct gl_program *
return GL_TRUE;
}
-static GLboolean evergreenIsProgramNative(GLcontext * ctx, GLenum target, struct gl_program *prog)
+static GLboolean evergreenIsProgramNative(struct gl_context * ctx, GLenum target, struct gl_program *prog)
{
return GL_TRUE;
diff --git a/src/mesa/drivers/dri/r600/evergreen_render.c b/src/mesa/drivers/dri/r600/evergreen_render.c
index 27089bfcf75..0c0eeca1fc5 100644
--- a/src/mesa/drivers/dri/r600/evergreen_render.c
+++ b/src/mesa/drivers/dri/r600/evergreen_render.c
@@ -148,7 +148,7 @@ static int evergreenNumVerts(int num_verts, int prim) //same
return num_verts - verts_off;
}
-static void evergreenRunRenderPrimitive(GLcontext * ctx, int start, int end, int prim,
+static void evergreenRunRenderPrimitive(struct gl_context * ctx, int start, int end, int prim,
GLint basevertex) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -219,7 +219,7 @@ static void evergreenRunRenderPrimitive(GLcontext * ctx, int start, int end, int
COMMIT_BATCH();
}
-static void evergreenRunRenderPrimitiveImmediate(GLcontext * ctx, int start, int end, int prim) //same
+static void evergreenRunRenderPrimitiveImmediate(struct gl_context * ctx, int start, int end, int prim) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
BATCH_LOCALS(&context->radeon);
@@ -363,7 +363,7 @@ static void evergreenRunRenderPrimitiveImmediate(GLcontext * ctx, int start, int
* Convert attribute data type to float
* If the attribute uses named buffer object replace the bo with newly allocated bo
*/
-static void evergreenConvertAttrib(GLcontext *ctx, int count,
+static void evergreenConvertAttrib(struct gl_context *ctx, int count,
const struct gl_client_array *input,
struct StreamDesc *attr)
{
@@ -442,7 +442,7 @@ static void evergreenConvertAttrib(GLcontext *ctx, int count,
}
}
-static void evergreenFixupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
+static void evergreenFixupIndexBuffer(struct gl_context *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
GLvoid *src_ptr;
@@ -517,7 +517,7 @@ static void evergreenFixupIndexBuffer(GLcontext *ctx, const struct _mesa_index_b
}
}
-static GLboolean evergreen_check_fallbacks(GLcontext *ctx) //same
+static GLboolean evergreen_check_fallbacks(struct gl_context *ctx) //same
{
if (ctx->RenderMode != GL_RENDER)
return GL_TRUE;
@@ -528,7 +528,7 @@ static GLboolean evergreen_check_fallbacks(GLcontext *ctx) //same
/* start 3d, idle, cb/db flush */
#define PRE_EMIT_STATE_BUFSZ 5 + 5 + 14
-static GLuint evergreenPredictRenderSize(GLcontext* ctx,
+static GLuint evergreenPredictRenderSize(struct gl_context* ctx,
const struct _mesa_prim *prim,
const struct _mesa_index_buffer *ib,
GLuint nr_prims)
@@ -567,7 +567,7 @@ static GLuint evergreenPredictRenderSize(GLcontext* ctx,
}
-static void evergreenSetupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
+static void evergreenSetupIndexBuffer(struct gl_context *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -620,7 +620,7 @@ static void evergreenSetupIndexBuffer(GLcontext *ctx, const struct _mesa_index_b
}
}
-static void evergreenAlignDataToDword(GLcontext *ctx,
+static void evergreenAlignDataToDword(struct gl_context *ctx,
const struct gl_client_array *input,
int count,
struct StreamDesc *attr)
@@ -662,7 +662,7 @@ static void evergreenAlignDataToDword(GLcontext *ctx,
attr->stride = dst_stride;
}
-static void evergreenSetupStreams(GLcontext *ctx, const struct gl_client_array *input[], int count)
+static void evergreenSetupStreams(struct gl_context *ctx, const struct gl_client_array *input[], int count)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
GLuint stride;
@@ -763,7 +763,7 @@ static void evergreenSetupStreams(GLcontext *ctx, const struct gl_client_array *
RADEON_GEM_DOMAIN_GTT, 0);
}
-static void evergreenFreeData(GLcontext *ctx)
+static void evergreenFreeData(struct gl_context *ctx)
{
/* Need to zero tcl.aos[n].bo and tcl.elt_dma_bo
* to prevent double unref in radeonReleaseArrays
@@ -799,7 +799,7 @@ static void evergreenFreeData(GLcontext *ctx)
}
}
-static GLboolean evergreenTryDrawPrims(GLcontext *ctx,
+static GLboolean evergreenTryDrawPrims(struct gl_context *ctx,
const struct gl_client_array *arrays[],
const struct _mesa_prim *prim,
GLuint nr_prims,
@@ -898,7 +898,7 @@ static GLboolean evergreenTryDrawPrims(GLcontext *ctx,
return GL_TRUE;
}
-static void evergreenDrawPrims(GLcontext *ctx,
+static void evergreenDrawPrims(struct gl_context *ctx,
const struct gl_client_array *arrays[],
const struct _mesa_prim *prim,
GLuint nr_prims,
@@ -932,7 +932,7 @@ static void evergreenDrawPrims(GLcontext *ctx,
}
}
-void evergreenInitDraw(GLcontext *ctx)
+void evergreenInitDraw(struct gl_context *ctx)
{
struct vbo_context *vbo = vbo_context(ctx);
diff --git a/src/mesa/drivers/dri/r600/evergreen_state.c b/src/mesa/drivers/dri/r600/evergreen_state.c
index 69c5ab656ea..a77be183a12 100644
--- a/src/mesa/drivers/dri/r600/evergreen_state.c
+++ b/src/mesa/drivers/dri/r600/evergreen_state.c
@@ -53,9 +53,9 @@
#include "evergreen_fragprog.h"
#include "evergreen_tex.h"
-void evergreenUpdateStateParameters(GLcontext * ctx, GLuint new_state); //same
+void evergreenUpdateStateParameters(struct gl_context * ctx, GLuint new_state); //same
-void evergreenUpdateShaders(GLcontext * ctx)
+void evergreenUpdateShaders(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -73,7 +73,7 @@ void evergreenUpdateShaders(GLcontext * ctx)
context->radeon.NewGLState = 0;
}
-void evergreeUpdateShaders(GLcontext * ctx)
+void evergreeUpdateShaders(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
@@ -94,7 +94,7 @@ void evergreeUpdateShaders(GLcontext * ctx)
/*
* To correctly position primitives:
*/
-void evergreenUpdateViewportOffset(GLcontext * ctx) //------------------
+void evergreenUpdateViewportOffset(struct gl_context * ctx) //------------------
{
context_t *context = R700_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -120,7 +120,7 @@ void evergreenUpdateViewportOffset(GLcontext * ctx) //------------------
radeonUpdateScissor(ctx);
}
-void evergreenUpdateStateParameters(GLcontext * ctx, GLuint new_state) //same
+void evergreenUpdateStateParameters(struct gl_context * ctx, GLuint new_state) //same
{
struct evergreen_fragment_program *fp =
(struct evergreen_fragment_program *)ctx->FragmentProgram._Current;
@@ -144,7 +144,7 @@ void evergreenUpdateStateParameters(GLcontext * ctx, GLuint new_state) //same
/**
* Called by Mesa after an internal state update.
*/
-static void evergreenInvalidateState(GLcontext * ctx, GLuint new_state) //same
+static void evergreenInvalidateState(struct gl_context * ctx, GLuint new_state) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -212,7 +212,7 @@ static void evergreenInvalidateState(GLcontext * ctx, GLuint new_state) //same
context->radeon.NewGLState |= new_state;
}
-static void evergreenSetAlphaState(GLcontext * ctx) //same
+static void evergreenSetAlphaState(struct gl_context * ctx) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -259,14 +259,14 @@ static void evergreenSetAlphaState(GLcontext * ctx) //same
}
}
-static void evergreenAlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref) //same
+static void evergreenAlphaFunc(struct gl_context * ctx, GLenum func, GLfloat ref) //same
{
(void)func;
(void)ref;
evergreenSetAlphaState(ctx);
}
-static void evergreenBlendColor(GLcontext * ctx, const GLfloat cf[4]) //same
+static void evergreenBlendColor(struct gl_context * ctx, const GLfloat cf[4]) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -334,7 +334,7 @@ static int evergreenblend_factor(GLenum factor, GLboolean is_src) //same
}
}
-static void evergreenSetBlendState(GLcontext * ctx) //diff : CB_COLOR_CONTROL, CB_BLEND0_CONTROL bits
+static void evergreenSetBlendState(struct gl_context * ctx) //diff : CB_COLOR_CONTROL, CB_BLEND0_CONTROL bits
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -459,13 +459,13 @@ static void evergreenSetBlendState(GLcontext * ctx) //diff : CB_COLOR_CONTROL, C
evergreen->CB_BLEND0_CONTROL.u32All = blend_reg;
}
-static void evergreenBlendEquationSeparate(GLcontext * ctx,
+static void evergreenBlendEquationSeparate(struct gl_context * ctx,
GLenum modeRGB, GLenum modeA) //same
{
evergreenSetBlendState(ctx);
}
-static void evergreenBlendFuncSeparate(GLcontext * ctx,
+static void evergreenBlendFuncSeparate(struct gl_context * ctx,
GLenum sfactorRGB, GLenum dfactorRGB,
GLenum sfactorA, GLenum dfactorA) //same
{
@@ -513,7 +513,7 @@ static GLuint evergreen_translate_logicop(GLenum logicop) //same
}
}
-static void evergreenSetLogicOpState(GLcontext *ctx) //diff : CB_COLOR_CONTROL.ROP3 is actually same bits.
+static void evergreenSetLogicOpState(struct gl_context *ctx) //diff : CB_COLOR_CONTROL.ROP3 is actually same bits.
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -531,7 +531,7 @@ static void evergreenSetLogicOpState(GLcontext *ctx) //diff : CB_COLOR_CONTROL.R
EG_CB_COLOR_CONTROL__ROP3_mask);
}
-static void evergreenClipPlane( GLcontext *ctx, GLenum plane, const GLfloat *eq ) //same , but PA_CL_UCP_0_ offset diff
+static void evergreenClipPlane( struct gl_context *ctx, GLenum plane, const GLfloat *eq ) //same , but PA_CL_UCP_0_ offset diff
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -549,7 +549,7 @@ static void evergreenClipPlane( GLcontext *ctx, GLenum plane, const GLfloat *eq
evergreen->ucp[p].PA_CL_UCP_0_W.u32All = ip[3];
}
-static void evergreenSetClipPlaneState(GLcontext * ctx, GLenum cap, GLboolean state) //diff in func calls
+static void evergreenSetClipPlaneState(struct gl_context * ctx, GLenum cap, GLboolean state) //diff in func calls
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -569,7 +569,7 @@ static void evergreenSetClipPlaneState(GLcontext * ctx, GLenum cap, GLboolean st
}
}
-static void evergreenSetDBRenderState(GLcontext * ctx)
+static void evergreenSetDBRenderState(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -629,13 +629,13 @@ static void evergreenSetDBRenderState(GLcontext * ctx)
}
}
-void evergreenUpdateShaderStates(GLcontext * ctx)
+void evergreenUpdateShaderStates(struct gl_context * ctx)
{
evergreenSetDBRenderState(ctx);
evergreenUpdateTextureState(ctx);
}
-static void evergreenSetDepthState(GLcontext * ctx) //same
+static void evergreenSetDepthState(struct gl_context * ctx) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -701,7 +701,7 @@ static void evergreenSetDepthState(GLcontext * ctx) //same
}
}
-static void evergreenSetStencilState(GLcontext * ctx, GLboolean state) //same
+static void evergreenSetStencilState(struct gl_context * ctx, GLboolean state) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -724,7 +724,7 @@ static void evergreenSetStencilState(GLcontext * ctx, GLboolean state) //same
}
}
-static void evergreenUpdateCulling(GLcontext * ctx) //same
+static void evergreenUpdateCulling(struct gl_context * ctx) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -776,7 +776,7 @@ static void evergreenUpdateCulling(GLcontext * ctx) //same
evergreen->PA_SU_SC_MODE_CNTL.u32All ^= FACE_bit;
}
-static void evergreenSetPolygonOffsetState(GLcontext * ctx, GLboolean state) //same
+static void evergreenSetPolygonOffsetState(struct gl_context * ctx, GLboolean state) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -794,7 +794,7 @@ static void evergreenSetPolygonOffsetState(GLcontext * ctx, GLboolean state) //s
}
}
-static void evergreenUpdateLineStipple(GLcontext * ctx) //diff
+static void evergreenUpdateLineStipple(struct gl_context * ctx) //diff
{
/* TODO */
}
@@ -913,7 +913,7 @@ void evergreenSetScissor(context_t *context) //diff
evergreen->viewport[id].enabled = GL_TRUE;
}
-static void evergreenUpdateWindow(GLcontext * ctx, int id) //diff in calling evergreenSetScissor
+static void evergreenUpdateWindow(struct gl_context * ctx, int id) //diff in calling evergreenSetScissor
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -969,7 +969,7 @@ static void evergreenUpdateWindow(GLcontext * ctx, int id) //diff in calling eve
evergreenSetScissor(context);
}
-static void evergreenEnable(GLcontext * ctx, GLenum cap, GLboolean state) //diff in func calls
+static void evergreenEnable(struct gl_context * ctx, GLenum cap, GLboolean state) //diff in func calls
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -1030,7 +1030,7 @@ static void evergreenEnable(GLcontext * ctx, GLenum cap, GLboolean state) //diff
}
-static void evergreenColorMask(GLcontext * ctx,
+static void evergreenColorMask(struct gl_context * ctx,
GLboolean r, GLboolean g, GLboolean b, GLboolean a) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -1046,26 +1046,26 @@ static void evergreenColorMask(GLcontext * ctx,
}
}
-static void evergreenDepthFunc(GLcontext * ctx, GLenum func) //same
+static void evergreenDepthFunc(struct gl_context * ctx, GLenum func) //same
{
evergreenSetDepthState(ctx);
}
-static void evergreenDepthMask(GLcontext * ctx, GLboolean mask) //same
+static void evergreenDepthMask(struct gl_context * ctx, GLboolean mask) //same
{
evergreenSetDepthState(ctx);
}
-static void evergreenCullFace(GLcontext * ctx, GLenum mode) //same
+static void evergreenCullFace(struct gl_context * ctx, GLenum mode) //same
{
evergreenUpdateCulling(ctx);
}
-static void evergreenFogfv(GLcontext * ctx, GLenum pname, const GLfloat * param) //same
+static void evergreenFogfv(struct gl_context * ctx, GLenum pname, const GLfloat * param) //same
{
}
-static void evergreenUpdatePolygonMode(GLcontext * ctx) //same
+static void evergreenUpdatePolygonMode(struct gl_context * ctx) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1120,13 +1120,13 @@ static void evergreenUpdatePolygonMode(GLcontext * ctx) //same
}
}
-static void evergreenFrontFace(GLcontext * ctx, GLenum mode) //same
+static void evergreenFrontFace(struct gl_context * ctx, GLenum mode) //same
{
evergreenUpdateCulling(ctx);
evergreenUpdatePolygonMode(ctx);
}
-static void evergreenShadeModel(GLcontext * ctx, GLenum mode) //same
+static void evergreenShadeModel(struct gl_context * ctx, GLenum mode) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1146,13 +1146,13 @@ static void evergreenShadeModel(GLcontext * ctx, GLenum mode) //same
}
}
-static void evergreenLogicOpcode(GLcontext *ctx, GLenum logicop) //diff
+static void evergreenLogicOpcode(struct gl_context *ctx, GLenum logicop) //diff
{
if (RGBA_LOGICOP_ENABLED(ctx))
evergreenSetLogicOpState(ctx);
}
-static void evergreenPointSize(GLcontext * ctx, GLfloat size) //same
+static void evergreenPointSize(struct gl_context * ctx, GLfloat size) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1174,7 +1174,7 @@ static void evergreenPointSize(GLcontext * ctx, GLfloat size) //same
}
-static void evergreenPointParameter(GLcontext * ctx, GLenum pname, const GLfloat * param) //same
+static void evergreenPointParameter(struct gl_context * ctx, GLenum pname, const GLfloat * param) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1225,7 +1225,7 @@ static int evergreen_translate_stencil_func(int func) //same
return 0;
}
-static void evergreenStencilFuncSeparate(GLcontext * ctx, GLenum face,
+static void evergreenStencilFuncSeparate(struct gl_context * ctx, GLenum face,
GLenum func, GLint ref, GLuint mask) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -1254,7 +1254,7 @@ static void evergreenStencilFuncSeparate(GLcontext * ctx, GLenum face,
STENCILFUNC_BF_shift, STENCILFUNC_BF_mask);
}
-static void evergreenStencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask) //same
+static void evergreenStencilMaskSeparate(struct gl_context * ctx, GLenum face, GLuint mask) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1298,7 +1298,7 @@ static int evergreen_translate_stencil_op(int op) //same
return 0;
}
-static void evergreenStencilOpSeparate(GLcontext * ctx, GLenum face,
+static void evergreenStencilOpSeparate(struct gl_context * ctx, GLenum face,
GLenum fail, GLenum zfail, GLenum zpass) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -1322,7 +1322,7 @@ static void evergreenStencilOpSeparate(GLcontext * ctx, GLenum face,
STENCILZPASS_BF_shift, STENCILZPASS_BF_mask);
}
-static void evergreenViewport(GLcontext * ctx,
+static void evergreenViewport(struct gl_context * ctx,
GLint x,
GLint y,
GLsizei width,
@@ -1333,12 +1333,12 @@ static void evergreenViewport(GLcontext * ctx,
radeon_viewport(ctx, x, y, width, height);
}
-static void evergreenDepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval) //diff in evergreenUpdateWindow
+static void evergreenDepthRange(struct gl_context * ctx, GLclampd nearval, GLclampd farval) //diff in evergreenUpdateWindow
{
evergreenUpdateWindow(ctx, 0);
}
-static void evergreenLineWidth(GLcontext * ctx, GLfloat widthf) //same
+static void evergreenLineWidth(struct gl_context * ctx, GLfloat widthf) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1352,7 +1352,7 @@ static void evergreenLineWidth(GLcontext * ctx, GLfloat widthf) //same
PA_SU_LINE_CNTL__WIDTH_shift, PA_SU_LINE_CNTL__WIDTH_mask);
}
-static void evergreenLineStipple(GLcontext *ctx, GLint factor, GLushort pattern) //same
+static void evergreenLineStipple(struct gl_context *ctx, GLint factor, GLushort pattern) //same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1364,7 +1364,7 @@ static void evergreenLineStipple(GLcontext *ctx, GLint factor, GLushort pattern)
SETfield(evergreen->PA_SC_LINE_STIPPLE.u32All, 1, AUTO_RESET_CNTL_shift, AUTO_RESET_CNTL_mask);
}
-static void evergreenPolygonOffset(GLcontext * ctx, GLfloat factor, GLfloat units) //diff :
+static void evergreenPolygonOffset(struct gl_context * ctx, GLfloat factor, GLfloat units) //diff :
//all register here offset diff, bits same
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -1395,7 +1395,7 @@ static void evergreenPolygonOffset(GLcontext * ctx, GLfloat factor, GLfloat unit
evergreen->PA_SU_POLY_OFFSET_BACK_OFFSET.f32All = constant;
}
-static void evergreenPolygonMode(GLcontext * ctx, GLenum face, GLenum mode) //same
+static void evergreenPolygonMode(struct gl_context * ctx, GLenum face, GLenum mode) //same
{
(void)face;
(void)mode;
@@ -1403,12 +1403,12 @@ static void evergreenPolygonMode(GLcontext * ctx, GLenum face, GLenum mode) //sa
evergreenUpdatePolygonMode(ctx);
}
-static void evergreenRenderMode(GLcontext * ctx, GLenum mode) //same
+static void evergreenRenderMode(struct gl_context * ctx, GLenum mode) //same
{
}
//TODO : move to kernel.
-static void evergreenInitSQConfig(GLcontext * ctx)
+static void evergreenInitSQConfig(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -1608,7 +1608,7 @@ static void evergreenInitSQConfig(GLcontext * ctx)
NUM_CLIP_SEQ_mask);
}
-void evergreenInitState(GLcontext * ctx) //diff
+void evergreenInitState(struct gl_context * ctx) //diff
{
context_t *context = R700_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
diff --git a/src/mesa/drivers/dri/r600/evergreen_state.h b/src/mesa/drivers/dri/r600/evergreen_state.h
index ffdb56b38ae..2f350e90faa 100644
--- a/src/mesa/drivers/dri/r600/evergreen_state.h
+++ b/src/mesa/drivers/dri/r600/evergreen_state.h
@@ -31,15 +31,15 @@
#include "r600_context.h"
-extern void evergreenUpdateStateParameters(GLcontext * ctx, GLuint new_state);
-extern void evergreenUpdateShaders(GLcontext * ctx);
-extern void evergreenUpdateShaderStates(GLcontext * ctx);
+extern void evergreenUpdateStateParameters(struct gl_context * ctx, GLuint new_state);
+extern void evergreenUpdateShaders(struct gl_context * ctx);
+extern void evergreenUpdateShaderStates(struct gl_context * ctx);
-extern void evergreeUpdateShaders(GLcontext * ctx);
+extern void evergreeUpdateShaders(struct gl_context * ctx);
-extern void evergreenUpdateViewportOffset(GLcontext * ctx);
+extern void evergreenUpdateViewportOffset(struct gl_context * ctx);
-extern void evergreenInitState(GLcontext * ctx);
+extern void evergreenInitState(struct gl_context * ctx);
extern void evergreenInitStateFuncs (radeonContextPtr radeon, struct dd_function_table *functions);
extern void evergreenSetScissor(context_t *context);
diff --git a/src/mesa/drivers/dri/r600/evergreen_tex.c b/src/mesa/drivers/dri/r600/evergreen_tex.c
index 8b42045ebb6..58420ed1239 100644
--- a/src/mesa/drivers/dri/r600/evergreen_tex.c
+++ b/src/mesa/drivers/dri/r600/evergreen_tex.c
@@ -934,7 +934,7 @@ EG_S_FIXED(float value, uint32_t frac_bits)
return value * (1 << frac_bits);
}
-static GLboolean evergreen_setup_hardware_state(GLcontext * ctx, struct gl_texture_object *texObj, int unit)
+static GLboolean evergreen_setup_hardware_state(struct gl_context * ctx, struct gl_texture_object *texObj, int unit)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
radeonTexObj *t = radeon_tex_obj(texObj);
@@ -1289,7 +1289,7 @@ void evergreenSetTexBuffer(__DRIcontext *pDRICtx, GLint target, GLint glx_textur
return;
}
-void evergreenUpdateTextureState(GLcontext * ctx)
+void evergreenUpdateTextureState(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT * evergreen = GET_EVERGREEN_CHIP(context);
@@ -1311,7 +1311,7 @@ void evergreenUpdateTextureState(GLcontext * ctx)
}
}
-static GLboolean evergreen_validate_texture(GLcontext * ctx, struct gl_texture_object *texObj, int unit)
+static GLboolean evergreen_validate_texture(struct gl_context * ctx, struct gl_texture_object *texObj, int unit)
{
radeonTexObj *t = radeon_tex_obj(texObj);
@@ -1327,7 +1327,7 @@ static GLboolean evergreen_validate_texture(GLcontext * ctx, struct gl_texture_o
return GL_TRUE;
}
-GLboolean evergreenValidateBuffers(GLcontext * ctx)
+GLboolean evergreenValidateBuffers(struct gl_context * ctx)
{
context_t *rmesa = EVERGREEN_CONTEXT(ctx);
struct radeon_renderbuffer *rrb;
@@ -1403,7 +1403,7 @@ GLboolean evergreenValidateBuffers(GLcontext * ctx)
return GL_TRUE;
}
-static struct gl_texture_object *evergreenNewTextureObject(GLcontext * ctx,
+static struct gl_texture_object *evergreenNewTextureObject(struct gl_context * ctx,
GLuint name,
GLenum target)
{
@@ -1426,7 +1426,7 @@ static struct gl_texture_object *evergreenNewTextureObject(GLcontext * ctx,
return &t->base;
}
-static void evergreenDeleteTexture(GLcontext * ctx, struct gl_texture_object *texObj)
+static void evergreenDeleteTexture(struct gl_context * ctx, struct gl_texture_object *texObj)
{
context_t * rmesa = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT * evergreen = GET_EVERGREEN_CHIP(rmesa);
@@ -1456,7 +1456,7 @@ static void evergreenDeleteTexture(GLcontext * ctx, struct gl_texture_object *te
_mesa_delete_texture_object(ctx, texObj);
}
-static void evergreenTexParameter(GLcontext * ctx, GLenum target,
+static void evergreenTexParameter(struct gl_context * ctx, GLenum target,
struct gl_texture_object *texObj,
GLenum pname, const GLfloat * params)
{
diff --git a/src/mesa/drivers/dri/r600/evergreen_tex.h b/src/mesa/drivers/dri/r600/evergreen_tex.h
index b43508a9eab..982a087f8ed 100644
--- a/src/mesa/drivers/dri/r600/evergreen_tex.h
+++ b/src/mesa/drivers/dri/r600/evergreen_tex.h
@@ -27,9 +27,9 @@
#ifndef _EVERGREEN_TEX_H_
#define _EVERGREEN_TEX_H_
-extern GLboolean evergreenValidateBuffers(GLcontext * ctx);
+extern GLboolean evergreenValidateBuffers(struct gl_context * ctx);
-extern void evergreenUpdateTextureState(GLcontext * ctx);
+extern void evergreenUpdateTextureState(struct gl_context * ctx);
extern void evergreenInitTextureFuncs(radeonContextPtr radeon, struct dd_function_table *functions);
extern void evergreenSetTexOffset(__DRIcontext * pDRICtx, GLint texname,
unsigned long long offset, GLint depth, GLuint pitch);
diff --git a/src/mesa/drivers/dri/r600/evergreen_vertprog.c b/src/mesa/drivers/dri/r600/evergreen_vertprog.c
index 0099cef527a..b3371f20b19 100644
--- a/src/mesa/drivers/dri/r600/evergreen_vertprog.c
+++ b/src/mesa/drivers/dri/r600/evergreen_vertprog.c
@@ -169,7 +169,7 @@ GLboolean evergreen_Process_Vertex_Program_Vfetch_Instructions(
}
GLboolean evergreen_Process_Vertex_Program_Vfetch_Instructions2(
- GLcontext *ctx,
+ struct gl_context *ctx,
struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp)
{
@@ -196,7 +196,7 @@ GLboolean evergreen_Process_Vertex_Program_Vfetch_Instructions2(
return GL_TRUE;
}
-void evergreen_Map_Vertex_Program(GLcontext *ctx,
+void evergreen_Map_Vertex_Program(struct gl_context *ctx,
struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp)
{
@@ -292,7 +292,7 @@ GLboolean evergreen_Find_Instruction_Dependencies_vp(struct evergreen_vertex_pro
return GL_TRUE;
}
-struct evergreen_vertex_program* evergreenTranslateVertexShader(GLcontext *ctx,
+struct evergreen_vertex_program* evergreenTranslateVertexShader(struct gl_context *ctx,
struct gl_vertex_program *mesa_vp)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -374,7 +374,7 @@ struct evergreen_vertex_program* evergreenTranslateVertexShader(GLcontext *ctx,
return vp;
}
-void evergreenSelectVertexShader(GLcontext *ctx)
+void evergreenSelectVertexShader(struct gl_context *ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_vertex_program_cont *vpc;
@@ -448,7 +448,7 @@ int evergreen_getTypeSize(GLenum type)
}
}
-static void evergreenTranslateAttrib(GLcontext *ctx, GLuint unLoc, int count, const struct gl_client_array *input)
+static void evergreenTranslateAttrib(struct gl_context *ctx, GLuint unLoc, int count, const struct gl_client_array *input)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
@@ -534,7 +534,7 @@ static void evergreenTranslateAttrib(GLcontext *ctx, GLuint unLoc, int count, co
context->nNumActiveAos++;
}
-void evergreenSetVertexFormat(GLcontext *ctx, const struct gl_client_array *arrays[], int count)
+void evergreenSetVertexFormat(struct gl_context *ctx, const struct gl_client_array *arrays[], int count)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_vertex_program *vpc
@@ -563,7 +563,7 @@ void evergreenSetVertexFormat(GLcontext *ctx, const struct gl_client_array *arra
context->radeon.tcl.aos_count = context->nNumActiveAos;
}
-void * evergreenGetActiveVpShaderBo(GLcontext * ctx)
+void * evergreenGetActiveVpShaderBo(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_vertex_program *vp = context->selected_vp;;
@@ -574,7 +574,7 @@ void * evergreenGetActiveVpShaderBo(GLcontext * ctx)
return NULL;
}
-void * evergreenGetActiveVpShaderConstBo(GLcontext * ctx)
+void * evergreenGetActiveVpShaderConstBo(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
struct evergreen_vertex_program *vp = context->selected_vp;;
@@ -585,7 +585,7 @@ void * evergreenGetActiveVpShaderConstBo(GLcontext * ctx)
return NULL;
}
-GLboolean evergreenSetupVertexProgram(GLcontext * ctx)
+GLboolean evergreenSetupVertexProgram(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
@@ -646,7 +646,7 @@ GLboolean evergreenSetupVertexProgram(GLcontext * ctx)
return GL_TRUE;
}
-GLboolean evergreenSetupVPconstants(GLcontext * ctx)
+GLboolean evergreenSetupVPconstants(struct gl_context * ctx)
{
context_t *context = EVERGREEN_CONTEXT(ctx);
EVERGREEN_CHIP_CONTEXT *evergreen = GET_EVERGREEN_CHIP(context);
diff --git a/src/mesa/drivers/dri/r600/evergreen_vertprog.h b/src/mesa/drivers/dri/r600/evergreen_vertprog.h
index 58539021152..8163e369277 100644
--- a/src/mesa/drivers/dri/r600/evergreen_vertprog.h
+++ b/src/mesa/drivers/dri/r600/evergreen_vertprog.h
@@ -80,29 +80,29 @@ GLboolean evergreen_Process_Vertex_Program_Vfetch_Instructions(
struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
GLboolean evergreen_Process_Vertex_Program_Vfetch_Instructions2(
- GLcontext *ctx,
+ struct gl_context *ctx,
struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
-void evergreen_Map_Vertex_Program(GLcontext *ctx,
+void evergreen_Map_Vertex_Program(struct gl_context *ctx,
struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
GLboolean evergreen_Find_Instruction_Dependencies_vp(struct evergreen_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
-struct evergreen_vertex_program* evergreenTranslateVertexShader(GLcontext *ctx,
+struct evergreen_vertex_program* evergreenTranslateVertexShader(struct gl_context *ctx,
struct gl_vertex_program *mesa_vp);
/* Interface */
-extern void evergreenSelectVertexShader(GLcontext *ctx);
-extern void evergreenSetVertexFormat(GLcontext *ctx, const struct gl_client_array *arrays[], int count);
+extern void evergreenSelectVertexShader(struct gl_context *ctx);
+extern void evergreenSetVertexFormat(struct gl_context *ctx, const struct gl_client_array *arrays[], int count);
-extern GLboolean evergreenSetupVertexProgram(GLcontext * ctx);
+extern GLboolean evergreenSetupVertexProgram(struct gl_context * ctx);
-extern GLboolean evergreenSetupVPconstants(GLcontext * ctx);
+extern GLboolean evergreenSetupVPconstants(struct gl_context * ctx);
-extern void * evergreenGetActiveVpShaderBo(GLcontext * ctx);
+extern void * evergreenGetActiveVpShaderBo(struct gl_context * ctx);
-extern void * evergreenGetActiveVpShaderConstBo(GLcontext * ctx);
+extern void * evergreenGetActiveVpShaderConstBo(struct gl_context * ctx);
extern int evergreen_getTypeSize(GLenum type);
diff --git a/src/mesa/drivers/dri/r600/r600_blit.c b/src/mesa/drivers/dri/r600/r600_blit.c
index 3090c9f613b..31c32d62f9a 100644
--- a/src/mesa/drivers/dri/r600/r600_blit.c
+++ b/src/mesa/drivers/dri/r600/r600_blit.c
@@ -408,7 +408,7 @@ set_render_target(context_t *context, struct radeon_bo *bo, gl_format mesa_forma
}
-static inline void load_shaders(GLcontext * ctx)
+static inline void load_shaders(struct gl_context * ctx)
{
radeonContextPtr radeonctx = RADEON_CONTEXT(ctx);
@@ -1566,7 +1566,7 @@ static GLboolean validate_buffers(context_t *rmesa,
return GL_TRUE;
}
-unsigned r600_blit(GLcontext *ctx,
+unsigned r600_blit(struct gl_context *ctx,
struct radeon_bo *src_bo,
intptr_t src_offset,
gl_format src_mesaformat,
diff --git a/src/mesa/drivers/dri/r600/r600_blit.h b/src/mesa/drivers/dri/r600/r600_blit.h
index d56b21ba9b5..9dc8e2fec64 100644
--- a/src/mesa/drivers/dri/r600/r600_blit.h
+++ b/src/mesa/drivers/dri/r600/r600_blit.h
@@ -30,7 +30,7 @@
unsigned r600_check_blit(gl_format mesa_format);
-unsigned r600_blit(GLcontext *ctx,
+unsigned r600_blit(struct gl_context *ctx,
struct radeon_bo *src_bo,
intptr_t src_offset,
gl_format src_mesaformat,
diff --git a/src/mesa/drivers/dri/r600/r600_context.c b/src/mesa/drivers/dri/r600/r600_context.c
index 103f33d39e3..c882a9cce9e 100644
--- a/src/mesa/drivers/dri/r600/r600_context.c
+++ b/src/mesa/drivers/dri/r600/r600_context.c
@@ -208,7 +208,7 @@ static void r600_vtbl_pre_emit_atoms(radeonContextPtr radeon)
r700Start3D((context_t *)radeon);
}
-static void r600_fallback(GLcontext *ctx, GLuint bit, GLboolean mode)
+static void r600_fallback(struct gl_context *ctx, GLuint bit, GLboolean mode)
{
context_t *context = R700_CONTEXT(ctx);
if (mode)
@@ -249,7 +249,7 @@ static void r600_init_vtbl(radeonContextPtr radeon)
radeon->vtbl.is_format_renderable = r600IsFormatRenderable;
}
-static void r600InitConstValues(GLcontext *ctx, radeonScreenPtr screen)
+static void r600InitConstValues(struct gl_context *ctx, radeonScreenPtr screen)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -335,7 +335,7 @@ static void r600ParseOptions(context_t *r600, radeonScreenPtr screen)
}
-static void r600InitGLExtensions(GLcontext *ctx)
+static void r600InitGLExtensions(struct gl_context *ctx)
{
context_t *r600 = R700_CONTEXT(ctx);
#ifdef R600_ENABLE_GLSL_TEST
@@ -388,7 +388,7 @@ GLboolean r600CreateContext(gl_api api,
radeonScreenPtr screen = (radeonScreenPtr) (sPriv->private);
struct dd_function_table functions;
context_t *r600;
- GLcontext *ctx;
+ struct gl_context *ctx;
assert(glVisual);
assert(driContextPriv);
diff --git a/src/mesa/drivers/dri/r600/r600_context.h b/src/mesa/drivers/dri/r600/r600_context.h
index 1954d3429a7..d3dc901acf8 100644
--- a/src/mesa/drivers/dri/r600/r600_context.h
+++ b/src/mesa/drivers/dri/r600/r600_context.h
@@ -188,7 +188,7 @@ struct r600_context {
#define EVERGREEN_CONTEXT(ctx) ((context_t *)(ctx->DriverCtx))
#define R700_CONTEXT(ctx) ((context_t *)(ctx->DriverCtx))
-#define GL_CONTEXT(context) ((GLcontext *)(context->radeon.glCtx))
+#define GL_CONTEXT(context) ((struct gl_context *)(context->radeon.glCtx))
#define GET_EVERGREEN_CHIP(context) ((EVERGREEN_CHIP_CONTEXT*)(context->pChip))
@@ -232,10 +232,10 @@ extern void r700WaitForIdleClean(context_t *context);
extern void r700Start3D(context_t *context);
extern void r600InitAtoms(context_t *context);
-extern void r700InitDraw(GLcontext *ctx);
+extern void r700InitDraw(struct gl_context *ctx);
extern void evergreenInitAtoms(context_t *context);
-extern void evergreenInitDraw(GLcontext *ctx);
+extern void evergreenInitDraw(struct gl_context *ctx);
#define RADEON_D_CAPTURE 0
#define RADEON_D_PLAYBACK 1
diff --git a/src/mesa/drivers/dri/r600/r600_emit.c b/src/mesa/drivers/dri/r600/r600_emit.c
index a840106c144..53ece9a3505 100644
--- a/src/mesa/drivers/dri/r600/r600_emit.c
+++ b/src/mesa/drivers/dri/r600/r600_emit.c
@@ -49,7 +49,7 @@ void r600EmitCacheFlush(context_t *rmesa)
{
}
-GLboolean r600AllocShaderConsts(GLcontext * ctx,
+GLboolean r600AllocShaderConsts(struct gl_context * ctx,
void ** constbo,
int sizeinBYTE,
char * szShaderUsage)
@@ -93,7 +93,7 @@ shader_again_alloc:
return GL_TRUE;
}
-GLboolean r600EmitShaderConsts(GLcontext * ctx,
+GLboolean r600EmitShaderConsts(struct gl_context * ctx,
void * constbo,
int bo_offset,
GLvoid * data,
@@ -114,7 +114,7 @@ GLboolean r600EmitShaderConsts(GLcontext * ctx,
return GL_TRUE;
}
-GLboolean r600EmitShader(GLcontext * ctx,
+GLboolean r600EmitShader(struct gl_context * ctx,
void ** shaderbo,
GLvoid * data,
int sizeinDWORD,
@@ -163,7 +163,7 @@ shader_again_alloc:
return GL_TRUE;
}
-GLboolean r600DeleteShader(GLcontext * ctx,
+GLboolean r600DeleteShader(struct gl_context * ctx,
void * shaderbo)
{
struct radeon_bo * pbo = (struct radeon_bo *)shaderbo;
diff --git a/src/mesa/drivers/dri/r600/r600_emit.h b/src/mesa/drivers/dri/r600/r600_emit.h
index 259561539fa..c50b6060ca9 100644
--- a/src/mesa/drivers/dri/r600/r600_emit.h
+++ b/src/mesa/drivers/dri/r600/r600_emit.h
@@ -43,20 +43,20 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
void r600EmitCacheFlush(context_t *rmesa);
-extern GLboolean r600EmitShader(GLcontext * ctx,
+extern GLboolean r600EmitShader(struct gl_context * ctx,
void ** shaderbo,
GLvoid * data,
int sizeinDWORD,
char * szShaderUsage);
-extern GLboolean r600DeleteShader(GLcontext * ctx,
+extern GLboolean r600DeleteShader(struct gl_context * ctx,
void * shaderbo);
-extern GLboolean r600AllocShaderConsts(GLcontext * ctx,
+extern GLboolean r600AllocShaderConsts(struct gl_context * ctx,
void ** constbo,
int sizeinBYTE,
char * szShaderUsage);
-GLboolean r600EmitShaderConsts(GLcontext * ctx,
+GLboolean r600EmitShaderConsts(struct gl_context * ctx,
void * constbo,
int bo_offset,
GLvoid * data,
diff --git a/src/mesa/drivers/dri/r600/r600_tex.c b/src/mesa/drivers/dri/r600/r600_tex.c
index 512a52ede3e..d6a58f410cc 100644
--- a/src/mesa/drivers/dri/r600/r600_tex.c
+++ b/src/mesa/drivers/dri/r600/r600_tex.c
@@ -276,7 +276,7 @@ static void r600SetTexBorderColor(radeonTexObjPtr t, const GLfloat color[4])
* next UpdateTextureState
*/
-static void r600TexParameter(GLcontext * ctx, GLenum target,
+static void r600TexParameter(struct gl_context * ctx, GLenum target,
struct gl_texture_object *texObj,
GLenum pname, const GLfloat * params)
{
@@ -332,7 +332,7 @@ static void r600TexParameter(GLcontext * ctx, GLenum target,
}
}
-static void r600DeleteTexture(GLcontext * ctx, struct gl_texture_object *texObj)
+static void r600DeleteTexture(struct gl_context * ctx, struct gl_texture_object *texObj)
{
context_t* rmesa = R700_CONTEXT(ctx);
radeonTexObj* t = radeon_tex_obj(texObj);
@@ -368,7 +368,7 @@ static void r600DeleteTexture(GLcontext * ctx, struct gl_texture_object *texObj)
* allocate the default texture objects.
* Fixup MaxAnisotropy according to user preference.
*/
-static struct gl_texture_object *r600NewTextureObject(GLcontext * ctx,
+static struct gl_texture_object *r600NewTextureObject(struct gl_context * ctx,
GLuint name,
GLenum target)
{
diff --git a/src/mesa/drivers/dri/r600/r600_tex.h b/src/mesa/drivers/dri/r600/r600_tex.h
index 771affdfa60..256588429e8 100644
--- a/src/mesa/drivers/dri/r600/r600_tex.h
+++ b/src/mesa/drivers/dri/r600/r600_tex.h
@@ -56,7 +56,7 @@ extern void r600SetTexOffset(__DRIcontext *pDRICtx, GLint texname,
unsigned long long offset, GLint depth,
GLuint pitch);
-extern GLboolean r600ValidateBuffers(GLcontext * ctx);
+extern GLboolean r600ValidateBuffers(struct gl_context * ctx);
extern void r600InitTextureFuncs(radeonContextPtr radeon, struct dd_function_table *functions);
diff --git a/src/mesa/drivers/dri/r600/r600_texstate.c b/src/mesa/drivers/dri/r600/r600_texstate.c
index fd928cfe5d2..3869768bf0e 100644
--- a/src/mesa/drivers/dri/r600/r600_texstate.c
+++ b/src/mesa/drivers/dri/r600/r600_texstate.c
@@ -52,9 +52,9 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "evergreen_tex.h"
-void r600UpdateTextureState(GLcontext * ctx);
+void r600UpdateTextureState(struct gl_context * ctx);
-void r600UpdateTextureState(GLcontext * ctx)
+void r600UpdateTextureState(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -707,7 +707,7 @@ void r600SetDepthTexMode(struct gl_texture_object *tObj)
* \param rmesa Context pointer
* \param t the r300 texture object
*/
-static GLboolean setup_hardware_state(GLcontext * ctx, struct gl_texture_object *texObj, int unit)
+static GLboolean setup_hardware_state(struct gl_context * ctx, struct gl_texture_object *texObj, int unit)
{
context_t *rmesa = R700_CONTEXT(ctx);
radeonTexObj *t = radeon_tex_obj(texObj);
@@ -803,7 +803,7 @@ static GLboolean setup_hardware_state(GLcontext * ctx, struct gl_texture_object
*
* Mostly this means populating the texture object's mipmap tree.
*/
-static GLboolean r600_validate_texture(GLcontext * ctx, struct gl_texture_object *texObj, int unit)
+static GLboolean r600_validate_texture(struct gl_context * ctx, struct gl_texture_object *texObj, int unit)
{
radeonTexObj *t = radeon_tex_obj(texObj);
@@ -822,7 +822,7 @@ static GLboolean r600_validate_texture(GLcontext * ctx, struct gl_texture_object
/**
* Ensure all enabled and complete textures are uploaded along with any buffers being used.
*/
-GLboolean r600ValidateBuffers(GLcontext * ctx)
+GLboolean r600ValidateBuffers(struct gl_context * ctx)
{
context_t *rmesa = R700_CONTEXT(ctx);
struct radeon_renderbuffer *rrb;
diff --git a/src/mesa/drivers/dri/r600/r700_chip.c b/src/mesa/drivers/dri/r600/r700_chip.c
index 3bb194eb6d6..4ec2845ab44 100644
--- a/src/mesa/drivers/dri/r600/r700_chip.c
+++ b/src/mesa/drivers/dri/r600/r700_chip.c
@@ -39,7 +39,7 @@
#include "radeon_mipmap_tree.h"
-static void r700SendTexState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendTexState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -104,7 +104,7 @@ static void r700SendTexState(GLcontext *ctx, struct radeon_state_atom *atom)
#define SAMPLER_STRIDE 3
-static void r700SendTexSamplerState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendTexSamplerState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -141,7 +141,7 @@ static void r700SendTexSamplerState(GLcontext *ctx, struct radeon_state_atom *at
}
}
-static void r700SendTexBorderColorState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendTexBorderColorState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -167,7 +167,7 @@ static void r700SendTexBorderColorState(GLcontext *ctx, struct radeon_state_atom
}
extern int getTypeSize(GLenum type);
-static void r700SetupVTXConstants(GLcontext * ctx,
+static void r700SetupVTXConstants(struct gl_context * ctx,
void * pAos,
StreamDesc * pStreamDesc)
{
@@ -243,7 +243,7 @@ static void r700SetupVTXConstants(GLcontext * ctx,
}
-static void r700SendVTXState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendVTXState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_vertex_program *vp = context->selected_vp;
@@ -599,7 +599,7 @@ static void r700SetDepthTarget(context_t *context)
/* r700->DB_PREFETCH_LIMIT.bits.DEPTH_HEIGHT_TILE_MAX = (context->currentDraw->h >> 3) - 1; */ /* z buffer sie may much bigger than what need, so use actual used h. */
}
-static void r700SendDepthTargetState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendDepthTargetState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -646,7 +646,7 @@ static void r700SendDepthTargetState(GLcontext *ctx, struct radeon_state_atom *a
}
-static void r700SendRenderTargetState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendRenderTargetState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -724,7 +724,7 @@ static void r700SendRenderTargetState(GLcontext *ctx, struct radeon_state_atom *
}
-static void r700SendPSState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendPSState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -766,7 +766,7 @@ static void r700SendPSState(GLcontext *ctx, struct radeon_state_atom *atom)
}
-static void r700SendVSState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendVSState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -827,7 +827,7 @@ static void r700SendVSState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendFSState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendFSState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -869,7 +869,7 @@ static void r700SendFSState(GLcontext *ctx, struct radeon_state_atom *atom)
}
-static void r700SendViewportState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendViewportState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -903,7 +903,7 @@ static void r700SendViewportState(GLcontext *ctx, struct radeon_state_atom *atom
}
-static void r700SendSQConfig(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendSQConfig(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -940,7 +940,7 @@ static void r700SendSQConfig(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendUCPState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendUCPState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -962,7 +962,7 @@ static void r700SendUCPState(GLcontext *ctx, struct radeon_state_atom *atom)
}
}
-static void r700SendSPIState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendSPIState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1037,7 +1037,7 @@ static void r700SendSPIState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendVGTState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendVGTState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1083,7 +1083,7 @@ static void r700SendVGTState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendSXState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendSXState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1098,7 +1098,7 @@ static void r700SendSXState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendDBState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendDBState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1124,7 +1124,7 @@ static void r700SendDBState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendStencilState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendStencilState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1138,7 +1138,7 @@ static void r700SendStencilState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendCBState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendCBState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1168,7 +1168,7 @@ static void r700SendCBState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendCBCLRCMPState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendCBCLRCMPState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1184,7 +1184,7 @@ static void r700SendCBCLRCMPState(GLcontext *ctx, struct radeon_state_atom *atom
COMMIT_BATCH();
}
-static void r700SendCBBlendState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendCBBlendState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1216,7 +1216,7 @@ static void r700SendCBBlendState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendCBBlendColorState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendCBBlendColorState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1233,7 +1233,7 @@ static void r700SendCBBlendColorState(GLcontext *ctx, struct radeon_state_atom *
COMMIT_BATCH();
}
-static void r700SendSUState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendSUState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1251,7 +1251,7 @@ static void r700SendSUState(GLcontext *ctx, struct radeon_state_atom *atom)
}
-static void r700SendPolyState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendPolyState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1271,7 +1271,7 @@ static void r700SendPolyState(GLcontext *ctx, struct radeon_state_atom *atom)
}
-static void r700SendCLState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendCLState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1287,7 +1287,7 @@ static void r700SendCLState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendGBState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendGBState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1303,7 +1303,7 @@ static void r700SendGBState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendScissorState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendScissorState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1336,7 +1336,7 @@ static void r700SendScissorState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendSCState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendSCState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1353,7 +1353,7 @@ static void r700SendSCState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendAAState(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendAAState(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1368,7 +1368,7 @@ static void r700SendAAState(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendPSConsts(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendPSConsts(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1392,7 +1392,7 @@ static void r700SendPSConsts(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendVSConsts(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendVSConsts(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = R700_CONTEXT_STATES(context);
@@ -1417,7 +1417,7 @@ static void r700SendVSConsts(GLcontext *ctx, struct radeon_state_atom *atom)
COMMIT_BATCH();
}
-static void r700SendQueryBegin(GLcontext *ctx, struct radeon_state_atom *atom)
+static void r700SendQueryBegin(struct gl_context *ctx, struct radeon_state_atom *atom)
{
radeonContextPtr radeon = RADEON_CONTEXT(ctx);
struct radeon_query_object *query = radeon->query.current;
@@ -1443,12 +1443,12 @@ static void r700SendQueryBegin(GLcontext *ctx, struct radeon_state_atom *atom)
query->emitted_begin = GL_TRUE;
}
-static int check_always(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_always(struct gl_context *ctx, struct radeon_state_atom *atom)
{
return atom->cmd_size;
}
-static int check_cb(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_cb(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
int count = 7;
@@ -1460,7 +1460,7 @@ static int check_cb(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_blnd(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_blnd(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1485,7 +1485,7 @@ static int check_blnd(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_ucp(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_ucp(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1500,7 +1500,7 @@ static int check_ucp(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_vtx(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_vtx(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
int count = context->radeon.tcl.aos_count * 18;
@@ -1509,7 +1509,7 @@ static int check_vtx(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_tx(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_tx(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
unsigned int i, count = 0;
@@ -1526,7 +1526,7 @@ static int check_tx(GLcontext *ctx, struct radeon_state_atom *atom)
return count * 31;
}
-static int check_ps_consts(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_ps_consts(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1539,7 +1539,7 @@ static int check_ps_consts(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_vs_consts(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_vs_consts(struct gl_context *ctx, struct radeon_state_atom *atom)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1552,7 +1552,7 @@ static int check_vs_consts(GLcontext *ctx, struct radeon_state_atom *atom)
return count;
}
-static int check_queryobj(GLcontext *ctx, struct radeon_state_atom *atom)
+static int check_queryobj(struct gl_context *ctx, struct radeon_state_atom *atom)
{
radeonContextPtr radeon = RADEON_CONTEXT(ctx);
struct radeon_query_object *query = radeon->query.current;
diff --git a/src/mesa/drivers/dri/r600/r700_clear.c b/src/mesa/drivers/dri/r600/r700_clear.c
index d1008f28b9b..853dec9233c 100644
--- a/src/mesa/drivers/dri/r600/r700_clear.c
+++ b/src/mesa/drivers/dri/r600/r700_clear.c
@@ -45,7 +45,7 @@ static GLboolean r700ClearFast(context_t *context, GLbitfield mask)
return GL_FALSE;
}
-void r700Clear(GLcontext * ctx, GLbitfield mask)
+void r700Clear(struct gl_context * ctx, GLbitfield mask)
{
context_t *context = R700_CONTEXT(ctx);
radeonContextPtr radeon = &context->radeon;
diff --git a/src/mesa/drivers/dri/r600/r700_clear.h b/src/mesa/drivers/dri/r600/r700_clear.h
index bed1d3a90e5..de372ee3039 100644
--- a/src/mesa/drivers/dri/r600/r700_clear.h
+++ b/src/mesa/drivers/dri/r600/r700_clear.h
@@ -28,6 +28,6 @@
#ifndef __r700_CLEAR_H__
#define __r700_CLEAR_H__
-extern void r700Clear(GLcontext * ctx, GLbitfield mask);
+extern void r700Clear(struct gl_context * ctx, GLbitfield mask);
#endif /* __r700_CLEAR_H__ */
diff --git a/src/mesa/drivers/dri/r600/r700_fragprog.c b/src/mesa/drivers/dri/r600/r700_fragprog.c
index 217b0e27a4a..2a6a39dfbac 100644
--- a/src/mesa/drivers/dri/r600/r700_fragprog.c
+++ b/src/mesa/drivers/dri/r600/r700_fragprog.c
@@ -44,7 +44,7 @@
#include "r700_debug.h"
-void insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fprog)
+void insert_wpos_code(struct gl_context *ctx, struct gl_fragment_program *fprog)
{
static const gl_state_index winstate[STATE_LENGTH]
= { STATE_INTERNAL, STATE_FB_SIZE, 0, 0, 0};
@@ -95,7 +95,7 @@ void insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fprog)
//TODO : Validate FP input with VP output.
void Map_Fragment_Program(r700_AssemblerBase *pAsm,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx)
+ struct gl_context *ctx)
{
unsigned int unBit;
unsigned int i;
@@ -353,7 +353,7 @@ GLboolean Find_Instruction_Dependencies_fp(struct r700_fragment_program *fp,
GLboolean r700TranslateFragmentShader(struct r700_fragment_program *fp,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx)
+ struct gl_context *ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -466,7 +466,7 @@ GLboolean r700TranslateFragmentShader(struct r700_fragment_program *fp,
return GL_TRUE;
}
-void r700SelectFragmentShader(GLcontext *ctx)
+void r700SelectFragmentShader(struct gl_context *ctx)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_fragment_program *fp = (struct r700_fragment_program *)
@@ -480,7 +480,7 @@ void r700SelectFragmentShader(GLcontext *ctx)
r700TranslateFragmentShader(fp, &(fp->mesa_program), ctx);
}
-void * r700GetActiveFpShaderBo(GLcontext * ctx)
+void * r700GetActiveFpShaderBo(struct gl_context * ctx)
{
struct r700_fragment_program *fp = (struct r700_fragment_program *)
(ctx->FragmentProgram._Current);
@@ -488,7 +488,7 @@ void * r700GetActiveFpShaderBo(GLcontext * ctx)
return fp->shaderbo;
}
-void * r700GetActiveFpShaderConstBo(GLcontext * ctx)
+void * r700GetActiveFpShaderConstBo(struct gl_context * ctx)
{
struct r700_fragment_program *fp = (struct r700_fragment_program *)
(ctx->FragmentProgram._Current);
@@ -496,7 +496,7 @@ void * r700GetActiveFpShaderConstBo(GLcontext * ctx)
return fp->constbo0;
}
-GLboolean r700SetupFragmentProgram(GLcontext * ctx)
+GLboolean r700SetupFragmentProgram(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
diff --git a/src/mesa/drivers/dri/r600/r700_fragprog.h b/src/mesa/drivers/dri/r600/r700_fragprog.h
index aaa6043d5d8..bdb95ff0e71 100644
--- a/src/mesa/drivers/dri/r600/r700_fragprog.h
+++ b/src/mesa/drivers/dri/r600/r700_fragprog.h
@@ -51,25 +51,25 @@ struct r700_fragment_program
};
/* Internal */
-void insert_wpos_code(GLcontext *ctx, struct gl_fragment_program *fprog);
+void insert_wpos_code(struct gl_context *ctx, struct gl_fragment_program *fprog);
void Map_Fragment_Program(r700_AssemblerBase *pAsm,
struct gl_fragment_program *mesa_fp,
- GLcontext *ctx);
+ struct gl_context *ctx);
GLboolean Find_Instruction_Dependencies_fp(struct r700_fragment_program *fp,
struct gl_fragment_program *mesa_fp);
GLboolean r700TranslateFragmentShader(struct r700_fragment_program *fp,
struct gl_fragment_program *mesa_vp,
- GLcontext *ctx);
+ struct gl_context *ctx);
/* Interface */
-extern void r700SelectFragmentShader(GLcontext *ctx);
+extern void r700SelectFragmentShader(struct gl_context *ctx);
-extern GLboolean r700SetupFragmentProgram(GLcontext * ctx);
+extern GLboolean r700SetupFragmentProgram(struct gl_context * ctx);
-extern void * r700GetActiveFpShaderBo(GLcontext * ctx);
+extern void * r700GetActiveFpShaderBo(struct gl_context * ctx);
-extern void * r700GetActiveFpShaderConstBo(GLcontext * ctx);
+extern void * r700GetActiveFpShaderConstBo(struct gl_context * ctx);
#endif /*_R700_FRAGPROG_H_*/
diff --git a/src/mesa/drivers/dri/r600/r700_oglprog.c b/src/mesa/drivers/dri/r600/r700_oglprog.c
index e0c9179004d..6ca74580035 100644
--- a/src/mesa/drivers/dri/r600/r700_oglprog.c
+++ b/src/mesa/drivers/dri/r600/r700_oglprog.c
@@ -40,7 +40,7 @@
#include "r700_vertprog.h"
-static void freeVertProgCache(GLcontext *ctx, struct r700_vertex_program_cont *cache)
+static void freeVertProgCache(struct gl_context *ctx, struct r700_vertex_program_cont *cache)
{
struct r700_vertex_program *tmp, *vp = cache->progs;
@@ -64,7 +64,7 @@ static void freeVertProgCache(GLcontext *ctx, struct r700_vertex_program_cont *c
}
}
-static struct gl_program *r700NewProgram(GLcontext * ctx,
+static struct gl_program *r700NewProgram(struct gl_context * ctx,
GLenum target,
GLuint id)
{
@@ -109,7 +109,7 @@ static struct gl_program *r700NewProgram(GLcontext * ctx,
return pProgram;
}
-static void r700DeleteProgram(GLcontext * ctx, struct gl_program *prog)
+static void r700DeleteProgram(struct gl_context * ctx, struct gl_program *prog)
{
struct r700_vertex_program_cont *vpc = (struct r700_vertex_program_cont *)prog;
struct r700_fragment_program * fp;
@@ -147,7 +147,7 @@ static void r700DeleteProgram(GLcontext * ctx, struct gl_program *prog)
}
static GLboolean
-r700ProgramStringNotify(GLcontext * ctx, GLenum target, struct gl_program *prog)
+r700ProgramStringNotify(struct gl_context * ctx, GLenum target, struct gl_program *prog)
{
struct r700_vertex_program_cont *vpc = (struct r700_vertex_program_cont *)prog;
struct r700_fragment_program * fp = (struct r700_fragment_program*)prog;
@@ -178,7 +178,7 @@ r700ProgramStringNotify(GLcontext * ctx, GLenum target, struct gl_program *prog)
return GL_TRUE;
}
-static GLboolean r700IsProgramNative(GLcontext * ctx, GLenum target, struct gl_program *prog)
+static GLboolean r700IsProgramNative(struct gl_context * ctx, GLenum target, struct gl_program *prog)
{
return GL_TRUE;
diff --git a/src/mesa/drivers/dri/r600/r700_render.c b/src/mesa/drivers/dri/r600/r700_render.c
index f90c69c4166..bb14a239b77 100644
--- a/src/mesa/drivers/dri/r600/r700_render.c
+++ b/src/mesa/drivers/dri/r600/r700_render.c
@@ -244,7 +244,7 @@ static int r700NumVerts(int num_verts, int prim)
return num_verts - verts_off;
}
-static void r700RunRenderPrimitive(GLcontext * ctx, int start, int end,
+static void r700RunRenderPrimitive(struct gl_context * ctx, int start, int end,
int prim, GLint basevertex)
{
context_t *context = R700_CONTEXT(ctx);
@@ -315,7 +315,7 @@ static void r700RunRenderPrimitive(GLcontext * ctx, int start, int end,
COMMIT_BATCH();
}
-static void r700RunRenderPrimitiveImmediate(GLcontext * ctx, int start, int end, int prim)
+static void r700RunRenderPrimitiveImmediate(struct gl_context * ctx, int start, int end, int prim)
{
context_t *context = R700_CONTEXT(ctx);
BATCH_LOCALS(&context->radeon);
@@ -434,7 +434,7 @@ static void r700RunRenderPrimitiveImmediate(GLcontext * ctx, int start, int end,
/* start 3d, idle, cb/db flush */
#define PRE_EMIT_STATE_BUFSZ 5 + 5 + 14
-static GLuint r700PredictRenderSize(GLcontext* ctx,
+static GLuint r700PredictRenderSize(struct gl_context* ctx,
const struct _mesa_prim *prim,
const struct _mesa_index_buffer *ib,
GLuint nr_prims)
@@ -501,7 +501,7 @@ static GLuint r700PredictRenderSize(GLcontext* ctx,
* Convert attribute data type to float
* If the attribute uses named buffer object replace the bo with newly allocated bo
*/
-static void r700ConvertAttrib(GLcontext *ctx, int count,
+static void r700ConvertAttrib(struct gl_context *ctx, int count,
const struct gl_client_array *input,
struct StreamDesc *attr)
{
@@ -580,7 +580,7 @@ static void r700ConvertAttrib(GLcontext *ctx, int count,
}
}
-static void r700AlignDataToDword(GLcontext *ctx,
+static void r700AlignDataToDword(struct gl_context *ctx,
const struct gl_client_array *input,
int count,
struct StreamDesc *attr)
@@ -622,7 +622,7 @@ static void r700AlignDataToDword(GLcontext *ctx,
attr->stride = dst_stride;
}
-static void r700SetupStreams(GLcontext *ctx, const struct gl_client_array *input[], int count)
+static void r700SetupStreams(struct gl_context *ctx, const struct gl_client_array *input[], int count)
{
context_t *context = R700_CONTEXT(ctx);
GLuint stride;
@@ -723,7 +723,7 @@ static void r700SetupStreams(GLcontext *ctx, const struct gl_client_array *input
RADEON_GEM_DOMAIN_GTT, 0);
}
-static void r700FreeData(GLcontext *ctx)
+static void r700FreeData(struct gl_context *ctx)
{
/* Need to zero tcl.aos[n].bo and tcl.elt_dma_bo
* to prevent double unref in radeonReleaseArrays
@@ -748,7 +748,7 @@ static void r700FreeData(GLcontext *ctx)
}
}
-static void r700FixupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
+static void r700FixupIndexBuffer(struct gl_context *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
{
context_t *context = R700_CONTEXT(ctx);
GLvoid *src_ptr;
@@ -823,7 +823,7 @@ static void r700FixupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer
}
}
-static void r700SetupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
+static void r700SetupIndexBuffer(struct gl_context *ctx, const struct _mesa_index_buffer *mesa_ind_buf)
{
context_t *context = R700_CONTEXT(ctx);
@@ -876,7 +876,7 @@ static void r700SetupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer
}
}
-static GLboolean check_fallbacks(GLcontext *ctx)
+static GLboolean check_fallbacks(struct gl_context *ctx)
{
if (ctx->RenderMode != GL_RENDER)
return GL_TRUE;
@@ -884,7 +884,7 @@ static GLboolean check_fallbacks(GLcontext *ctx)
return GL_FALSE;
}
-static GLboolean r700TryDrawPrims(GLcontext *ctx,
+static GLboolean r700TryDrawPrims(struct gl_context *ctx,
const struct gl_client_array *arrays[],
const struct _mesa_prim *prim,
GLuint nr_prims,
@@ -972,7 +972,7 @@ static GLboolean r700TryDrawPrims(GLcontext *ctx,
return GL_TRUE;
}
-static void r700DrawPrims(GLcontext *ctx,
+static void r700DrawPrims(struct gl_context *ctx,
const struct gl_client_array *arrays[],
const struct _mesa_prim *prim,
GLuint nr_prims,
@@ -1011,7 +1011,7 @@ static void r700DrawPrims(GLcontext *ctx,
}
}
-void r700InitDraw(GLcontext *ctx)
+void r700InitDraw(struct gl_context *ctx)
{
struct vbo_context *vbo = vbo_context(ctx);
diff --git a/src/mesa/drivers/dri/r600/r700_shader.c b/src/mesa/drivers/dri/r600/r700_shader.c
index 8b3ed5cd823..cbbfaed31c9 100644
--- a/src/mesa/drivers/dri/r600/r700_shader.c
+++ b/src/mesa/drivers/dri/r600/r700_shader.c
@@ -38,7 +38,7 @@
#include "r700_shader.h"
-void r700ShaderInit(GLcontext * ctx)
+void r700ShaderInit(struct gl_context * ctx)
{
}
diff --git a/src/mesa/drivers/dri/r600/r700_shader.h b/src/mesa/drivers/dri/r600/r700_shader.h
index 0599ffd901f..183dd33525f 100644
--- a/src/mesa/drivers/dri/r600/r700_shader.h
+++ b/src/mesa/drivers/dri/r600/r700_shader.h
@@ -33,7 +33,7 @@
#include "r700_shaderinst.h"
-void r700ShaderInit(GLcontext * ctx);
+void r700ShaderInit(struct gl_context * ctx);
typedef enum R700ShaderType
{
diff --git a/src/mesa/drivers/dri/r600/r700_state.c b/src/mesa/drivers/dri/r600/r700_state.c
index 925b4ffe6dd..bd04a633b48 100644
--- a/src/mesa/drivers/dri/r600/r700_state.c
+++ b/src/mesa/drivers/dri/r600/r700_state.c
@@ -52,14 +52,14 @@
#include "r700_fragprog.h"
#include "r700_vertprog.h"
-void r600UpdateTextureState(GLcontext * ctx);
-static void r700SetClipPlaneState(GLcontext * ctx, GLenum cap, GLboolean state);
-static void r700UpdatePolygonMode(GLcontext * ctx);
-static void r700SetPolygonOffsetState(GLcontext * ctx, GLboolean state);
-static void r700SetStencilState(GLcontext * ctx, GLboolean state);
-static void r700UpdateWindow(GLcontext * ctx, int id);
-
-void r700UpdateShaders(GLcontext * ctx)
+void r600UpdateTextureState(struct gl_context * ctx);
+static void r700SetClipPlaneState(struct gl_context * ctx, GLenum cap, GLboolean state);
+static void r700UpdatePolygonMode(struct gl_context * ctx);
+static void r700SetPolygonOffsetState(struct gl_context * ctx, GLboolean state);
+static void r700SetStencilState(struct gl_context * ctx, GLboolean state);
+static void r700UpdateWindow(struct gl_context * ctx, int id);
+
+void r700UpdateShaders(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
@@ -80,7 +80,7 @@ void r700UpdateShaders(GLcontext * ctx)
/*
* To correctly position primitives:
*/
-void r700UpdateViewportOffset(GLcontext * ctx) //------------------
+void r700UpdateViewportOffset(struct gl_context * ctx) //------------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -106,7 +106,7 @@ void r700UpdateViewportOffset(GLcontext * ctx) //------------------
radeonUpdateScissor(ctx);
}
-void r700UpdateStateParameters(GLcontext * ctx, GLuint new_state) //--------------------
+void r700UpdateStateParameters(struct gl_context * ctx, GLuint new_state) //--------------------
{
struct r700_fragment_program *fp =
(struct r700_fragment_program *)ctx->FragmentProgram._Current;
@@ -130,7 +130,7 @@ void r700UpdateStateParameters(GLcontext * ctx, GLuint new_state) //------------
/**
* Called by Mesa after an internal state update.
*/
-static void r700InvalidateState(GLcontext * ctx, GLuint new_state) //-------------------
+static void r700InvalidateState(struct gl_context * ctx, GLuint new_state) //-------------------
{
context_t *context = R700_CONTEXT(ctx);
@@ -190,7 +190,7 @@ static void r700InvalidateState(GLcontext * ctx, GLuint new_state) //-----------
context->radeon.NewGLState |= new_state;
}
-static void r700SetDBRenderState(GLcontext * ctx)
+static void r700SetDBRenderState(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -245,13 +245,13 @@ static void r700SetDBRenderState(GLcontext * ctx)
}
}
-void r700UpdateShaderStates(GLcontext * ctx)
+void r700UpdateShaderStates(struct gl_context * ctx)
{
r700SetDBRenderState(ctx);
r600UpdateTextureState(ctx);
}
-static void r700SetDepthState(GLcontext * ctx)
+static void r700SetDepthState(struct gl_context * ctx)
{
struct radeon_renderbuffer *rrb;
context_t *context = R700_CONTEXT(ctx);
@@ -320,7 +320,7 @@ static void r700SetDepthState(GLcontext * ctx)
}
}
-static void r700SetAlphaState(GLcontext * ctx)
+static void r700SetAlphaState(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -368,7 +368,7 @@ static void r700SetAlphaState(GLcontext * ctx)
}
-static void r700AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref) //---------------
+static void r700AlphaFunc(struct gl_context * ctx, GLenum func, GLfloat ref) //---------------
{
(void)func;
(void)ref;
@@ -376,7 +376,7 @@ static void r700AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref) //---------
}
-static void r700BlendColor(GLcontext * ctx, const GLfloat cf[4]) //----------------
+static void r700BlendColor(struct gl_context * ctx, const GLfloat cf[4]) //----------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -444,7 +444,7 @@ static int blend_factor(GLenum factor, GLboolean is_src)
}
}
-static void r700SetBlendState(GLcontext * ctx)
+static void r700SetBlendState(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -576,13 +576,13 @@ static void r700SetBlendState(GLcontext * ctx)
}
-static void r700BlendEquationSeparate(GLcontext * ctx,
+static void r700BlendEquationSeparate(struct gl_context * ctx,
GLenum modeRGB, GLenum modeA) //-----------------
{
r700SetBlendState(ctx);
}
-static void r700BlendFuncSeparate(GLcontext * ctx,
+static void r700BlendFuncSeparate(struct gl_context * ctx,
GLenum sfactorRGB, GLenum dfactorRGB,
GLenum sfactorA, GLenum dfactorA) //------------------------
{
@@ -637,7 +637,7 @@ static GLuint translate_logicop(GLenum logicop)
* Used internally to update the r300->hw hardware state to match the
* current OpenGL state.
*/
-static void r700SetLogicOpState(GLcontext *ctx)
+static void r700SetLogicOpState(struct gl_context *ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&R700_CONTEXT(ctx)->hw);
@@ -655,13 +655,13 @@ static void r700SetLogicOpState(GLcontext *ctx)
* Called by Mesa when an application program changes the LogicOp state
* via glLogicOp.
*/
-static void r700LogicOpcode(GLcontext *ctx, GLenum logicop)
+static void r700LogicOpcode(struct gl_context *ctx, GLenum logicop)
{
if (RGBA_LOGICOP_ENABLED(ctx))
r700SetLogicOpState(ctx);
}
-static void r700UpdateCulling(GLcontext * ctx)
+static void r700UpdateCulling(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&R700_CONTEXT(ctx)->hw);
@@ -713,7 +713,7 @@ static void r700UpdateCulling(GLcontext * ctx)
r700->PA_SU_SC_MODE_CNTL.u32All ^= FACE_bit;
}
-static void r700UpdateLineStipple(GLcontext * ctx)
+static void r700UpdateLineStipple(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&R700_CONTEXT(ctx)->hw);
@@ -730,7 +730,7 @@ static void r700UpdateLineStipple(GLcontext * ctx)
}
}
-static void r700Enable(GLcontext * ctx, GLenum cap, GLboolean state) //------------------
+static void r700Enable(struct gl_context * ctx, GLenum cap, GLboolean state) //------------------
{
context_t *context = R700_CONTEXT(ctx);
@@ -794,7 +794,7 @@ static void r700Enable(GLcontext * ctx, GLenum cap, GLboolean state) //---------
/**
* Handle glColorMask()
*/
-static void r700ColorMask(GLcontext * ctx,
+static void r700ColorMask(struct gl_context * ctx,
GLboolean r, GLboolean g, GLboolean b, GLboolean a) //------------------
{
context_t *context = R700_CONTEXT(ctx);
@@ -815,7 +815,7 @@ static void r700ColorMask(GLcontext * ctx,
*
* \note Mesa already filters redundant calls to this function.
*/
-static void r700DepthFunc(GLcontext * ctx, GLenum func) //--------------------
+static void r700DepthFunc(struct gl_context * ctx, GLenum func) //--------------------
{
r700SetDepthState(ctx);
}
@@ -825,7 +825,7 @@ static void r700DepthFunc(GLcontext * ctx, GLenum func) //--------------------
*
* \note Mesa already filters redundant calls to this function.
*/
-static void r700DepthMask(GLcontext * ctx, GLboolean mask) //------------------
+static void r700DepthMask(struct gl_context * ctx, GLboolean mask) //------------------
{
r700SetDepthState(ctx);
}
@@ -835,7 +835,7 @@ static void r700DepthMask(GLcontext * ctx, GLboolean mask) //------------------
*
* \note Mesa already filters redundant calls to this function.
*/
-static void r700CullFace(GLcontext * ctx, GLenum mode) //-----------------
+static void r700CullFace(struct gl_context * ctx, GLenum mode) //-----------------
{
r700UpdateCulling(ctx);
}
@@ -843,7 +843,7 @@ static void r700CullFace(GLcontext * ctx, GLenum mode) //-----------------
/* =============================================================
* Fog
*/
-static void r700Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param) //--------------
+static void r700Fogfv(struct gl_context * ctx, GLenum pname, const GLfloat * param) //--------------
{
}
@@ -852,13 +852,13 @@ static void r700Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param) //--
*
* \note Mesa already filters redundant calls to this function.
*/
-static void r700FrontFace(GLcontext * ctx, GLenum mode) //------------------
+static void r700FrontFace(struct gl_context * ctx, GLenum mode) //------------------
{
r700UpdateCulling(ctx);
r700UpdatePolygonMode(ctx);
}
-static void r700ShadeModel(GLcontext * ctx, GLenum mode) //--------------------
+static void r700ShadeModel(struct gl_context * ctx, GLenum mode) //--------------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -881,7 +881,7 @@ static void r700ShadeModel(GLcontext * ctx, GLenum mode) //--------------------
/* =============================================================
* Point state
*/
-static void r700PointSize(GLcontext * ctx, GLfloat size)
+static void r700PointSize(struct gl_context * ctx, GLfloat size)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -903,7 +903,7 @@ static void r700PointSize(GLcontext * ctx, GLfloat size)
}
-static void r700PointParameter(GLcontext * ctx, GLenum pname, const GLfloat * param) //---------------
+static void r700PointParameter(struct gl_context * ctx, GLenum pname, const GLfloat * param) //---------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -980,7 +980,7 @@ static int translate_stencil_op(int op)
return 0;
}
-static void r700SetStencilState(GLcontext * ctx, GLboolean state)
+static void r700SetStencilState(struct gl_context * ctx, GLboolean state)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1002,7 +1002,7 @@ static void r700SetStencilState(GLcontext * ctx, GLboolean state)
}
}
-static void r700StencilFuncSeparate(GLcontext * ctx, GLenum face,
+static void r700StencilFuncSeparate(struct gl_context * ctx, GLenum face,
GLenum func, GLint ref, GLuint mask) //---------------------
{
context_t *context = R700_CONTEXT(ctx);
@@ -1032,7 +1032,7 @@ static void r700StencilFuncSeparate(GLcontext * ctx, GLenum face,
}
-static void r700StencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask) //--------------
+static void r700StencilMaskSeparate(struct gl_context * ctx, GLenum face, GLuint mask) //--------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1050,7 +1050,7 @@ static void r700StencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask) /
}
-static void r700StencilOpSeparate(GLcontext * ctx, GLenum face,
+static void r700StencilOpSeparate(struct gl_context * ctx, GLenum face,
GLenum fail, GLenum zfail, GLenum zpass) //--------------------
{
context_t *context = R700_CONTEXT(ctx);
@@ -1074,7 +1074,7 @@ static void r700StencilOpSeparate(GLcontext * ctx, GLenum face,
STENCILZPASS_BF_shift, STENCILZPASS_BF_mask);
}
-static void r700UpdateWindow(GLcontext * ctx, int id) //--------------------
+static void r700UpdateWindow(struct gl_context * ctx, int id) //--------------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1131,7 +1131,7 @@ static void r700UpdateWindow(GLcontext * ctx, int id) //--------------------
}
-static void r700Viewport(GLcontext * ctx,
+static void r700Viewport(struct gl_context * ctx,
GLint x,
GLint y,
GLsizei width,
@@ -1142,12 +1142,12 @@ static void r700Viewport(GLcontext * ctx,
radeon_viewport(ctx, x, y, width, height);
}
-static void r700DepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval) //-------------
+static void r700DepthRange(struct gl_context * ctx, GLclampd nearval, GLclampd farval) //-------------
{
r700UpdateWindow(ctx, 0);
}
-static void r700LineWidth(GLcontext * ctx, GLfloat widthf) //---------------
+static void r700LineWidth(struct gl_context * ctx, GLfloat widthf) //---------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1161,7 +1161,7 @@ static void r700LineWidth(GLcontext * ctx, GLfloat widthf) //---------------
PA_SU_LINE_CNTL__WIDTH_shift, PA_SU_LINE_CNTL__WIDTH_mask);
}
-static void r700LineStipple(GLcontext *ctx, GLint factor, GLushort pattern)
+static void r700LineStipple(struct gl_context *ctx, GLint factor, GLushort pattern)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1173,7 +1173,7 @@ static void r700LineStipple(GLcontext *ctx, GLint factor, GLushort pattern)
SETfield(r700->PA_SC_LINE_STIPPLE.u32All, 1, AUTO_RESET_CNTL_shift, AUTO_RESET_CNTL_mask);
}
-static void r700SetPolygonOffsetState(GLcontext * ctx, GLboolean state)
+static void r700SetPolygonOffsetState(struct gl_context * ctx, GLboolean state)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1191,7 +1191,7 @@ static void r700SetPolygonOffsetState(GLcontext * ctx, GLboolean state)
}
}
-static void r700PolygonOffset(GLcontext * ctx, GLfloat factor, GLfloat units) //--------------
+static void r700PolygonOffset(struct gl_context * ctx, GLfloat factor, GLfloat units) //--------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1221,7 +1221,7 @@ static void r700PolygonOffset(GLcontext * ctx, GLfloat factor, GLfloat units) //
r700->PA_SU_POLY_OFFSET_BACK_OFFSET.f32All = constant;
}
-static void r700UpdatePolygonMode(GLcontext * ctx)
+static void r700UpdatePolygonMode(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1276,7 +1276,7 @@ static void r700UpdatePolygonMode(GLcontext * ctx)
}
}
-static void r700PolygonMode(GLcontext * ctx, GLenum face, GLenum mode) //------------------
+static void r700PolygonMode(struct gl_context * ctx, GLenum face, GLenum mode) //------------------
{
(void)face;
(void)mode;
@@ -1284,11 +1284,11 @@ static void r700PolygonMode(GLcontext * ctx, GLenum face, GLenum mode) //-------
r700UpdatePolygonMode(ctx);
}
-static void r700RenderMode(GLcontext * ctx, GLenum mode) //---------------------
+static void r700RenderMode(struct gl_context * ctx, GLenum mode) //---------------------
{
}
-static void r700ClipPlane( GLcontext *ctx, GLenum plane, const GLfloat *eq )
+static void r700ClipPlane( struct gl_context *ctx, GLenum plane, const GLfloat *eq )
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1306,7 +1306,7 @@ static void r700ClipPlane( GLcontext *ctx, GLenum plane, const GLfloat *eq )
r700->ucp[p].PA_CL_UCP_0_W.u32All = ip[3];
}
-static void r700SetClipPlaneState(GLcontext * ctx, GLenum cap, GLboolean state)
+static void r700SetClipPlaneState(struct gl_context * ctx, GLenum cap, GLboolean state)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1428,7 +1428,7 @@ void r700SetScissor(context_t *context) //---------------
r700->viewport[id].enabled = GL_TRUE;
}
-static void r700InitSQConfig(GLcontext * ctx)
+static void r700InitSQConfig(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
@@ -1635,7 +1635,7 @@ static void r700InitSQConfig(GLcontext * ctx)
* Assumes that the command buffer and state atoms have been
* initialized already.
*/
-void r700InitState(GLcontext * ctx) //-------------------
+void r700InitState(struct gl_context * ctx) //-------------------
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
diff --git a/src/mesa/drivers/dri/r600/r700_state.h b/src/mesa/drivers/dri/r600/r700_state.h
index 56885e0b154..2d51198c8a8 100644
--- a/src/mesa/drivers/dri/r600/r700_state.h
+++ b/src/mesa/drivers/dri/r600/r700_state.h
@@ -33,13 +33,13 @@
#include "r700_chip.h"
-extern void r700UpdateStateParameters(GLcontext * ctx, GLuint new_state);
-extern void r700UpdateShaders (GLcontext * ctx);
-extern void r700UpdateShaderStates(GLcontext * ctx);
+extern void r700UpdateStateParameters(struct gl_context * ctx, GLuint new_state);
+extern void r700UpdateShaders (struct gl_context * ctx);
+extern void r700UpdateShaderStates(struct gl_context * ctx);
-extern void r700UpdateViewportOffset(GLcontext * ctx);
+extern void r700UpdateViewportOffset(struct gl_context * ctx);
-extern void r700InitState (GLcontext * ctx);
+extern void r700InitState (struct gl_context * ctx);
extern void r700InitStateFuncs (radeonContextPtr radeon, struct dd_function_table *functions);
extern void r700SetScissor(context_t *context);
diff --git a/src/mesa/drivers/dri/r600/r700_vertprog.c b/src/mesa/drivers/dri/r600/r700_vertprog.c
index 2fee5b4433e..7ba49d8f986 100644
--- a/src/mesa/drivers/dri/r600/r700_vertprog.c
+++ b/src/mesa/drivers/dri/r600/r700_vertprog.c
@@ -170,7 +170,7 @@ GLboolean Process_Vertex_Program_Vfetch_Instructions(
}
GLboolean Process_Vertex_Program_Vfetch_Instructions2(
- GLcontext *ctx,
+ struct gl_context *ctx,
struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp)
{
@@ -197,7 +197,7 @@ GLboolean Process_Vertex_Program_Vfetch_Instructions2(
return GL_TRUE;
}
-void Map_Vertex_Program(GLcontext *ctx,
+void Map_Vertex_Program(struct gl_context *ctx,
struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp)
{
@@ -293,7 +293,7 @@ GLboolean Find_Instruction_Dependencies_vp(struct r700_vertex_program *vp,
return GL_TRUE;
}
-struct r700_vertex_program* r700TranslateVertexShader(GLcontext *ctx,
+struct r700_vertex_program* r700TranslateVertexShader(struct gl_context *ctx,
struct gl_vertex_program *mesa_vp)
{
context_t *context = R700_CONTEXT(ctx);
@@ -385,7 +385,7 @@ struct r700_vertex_program* r700TranslateVertexShader(GLcontext *ctx,
return vp;
}
-void r700SelectVertexShader(GLcontext *ctx)
+void r700SelectVertexShader(struct gl_context *ctx)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_vertex_program_cont *vpc;
@@ -459,7 +459,7 @@ int getTypeSize(GLenum type)
}
}
-static void r700TranslateAttrib(GLcontext *ctx, GLuint unLoc, int count, const struct gl_client_array *input)
+static void r700TranslateAttrib(struct gl_context *ctx, GLuint unLoc, int count, const struct gl_client_array *input)
{
context_t *context = R700_CONTEXT(ctx);
@@ -545,7 +545,7 @@ static void r700TranslateAttrib(GLcontext *ctx, GLuint unLoc, int count, const s
context->nNumActiveAos++;
}
-void r700SetVertexFormat(GLcontext *ctx, const struct gl_client_array *arrays[], int count)
+void r700SetVertexFormat(struct gl_context *ctx, const struct gl_client_array *arrays[], int count)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_vertex_program *vpc
@@ -574,7 +574,7 @@ void r700SetVertexFormat(GLcontext *ctx, const struct gl_client_array *arrays[],
context->radeon.tcl.aos_count = context->nNumActiveAos;
}
-void * r700GetActiveVpShaderBo(GLcontext * ctx)
+void * r700GetActiveVpShaderBo(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_vertex_program *vp = context->selected_vp;;
@@ -585,7 +585,7 @@ void * r700GetActiveVpShaderBo(GLcontext * ctx)
return NULL;
}
-void * r700GetActiveVpShaderConstBo(GLcontext * ctx)
+void * r700GetActiveVpShaderConstBo(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
struct r700_vertex_program *vp = context->selected_vp;;
@@ -596,7 +596,7 @@ void * r700GetActiveVpShaderConstBo(GLcontext * ctx)
return NULL;
}
-GLboolean r700SetupVertexProgram(GLcontext * ctx)
+GLboolean r700SetupVertexProgram(struct gl_context * ctx)
{
context_t *context = R700_CONTEXT(ctx);
R700_CHIP_CONTEXT *r700 = (R700_CHIP_CONTEXT*)(&context->hw);
diff --git a/src/mesa/drivers/dri/r600/r700_vertprog.h b/src/mesa/drivers/dri/r600/r700_vertprog.h
index 9acdc8e3501..859afb6e97c 100644
--- a/src/mesa/drivers/dri/r600/r700_vertprog.h
+++ b/src/mesa/drivers/dri/r600/r700_vertprog.h
@@ -80,27 +80,27 @@ GLboolean Process_Vertex_Program_Vfetch_Instructions(
struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
GLboolean Process_Vertex_Program_Vfetch_Instructions2(
- GLcontext *ctx,
+ struct gl_context *ctx,
struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
-void Map_Vertex_Program(GLcontext *ctx,
+void Map_Vertex_Program(struct gl_context *ctx,
struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
GLboolean Find_Instruction_Dependencies_vp(struct r700_vertex_program *vp,
struct gl_vertex_program *mesa_vp);
-struct r700_vertex_program* r700TranslateVertexShader(GLcontext *ctx,
+struct r700_vertex_program* r700TranslateVertexShader(struct gl_context *ctx,
struct gl_vertex_program *mesa_vp);
/* Interface */
-extern void r700SelectVertexShader(GLcontext *ctx);
-extern void r700SetVertexFormat(GLcontext *ctx, const struct gl_client_array *arrays[], int count);
+extern void r700SelectVertexShader(struct gl_context *ctx);
+extern void r700SetVertexFormat(struct gl_context *ctx, const struct gl_client_array *arrays[], int count);
-extern GLboolean r700SetupVertexProgram(GLcontext * ctx);
+extern GLboolean r700SetupVertexProgram(struct gl_context * ctx);
-extern void * r700GetActiveVpShaderBo(GLcontext * ctx);
+extern void * r700GetActiveVpShaderBo(struct gl_context * ctx);
-extern void * r700GetActiveVpShaderConstBo(GLcontext * ctx);
+extern void * r700GetActiveVpShaderConstBo(struct gl_context * ctx);
extern int getTypeSize(GLenum type);