Drop GLcontext typedef and use struct gl_context instead
This commit is contained in:
@@ -854,7 +854,7 @@ XMesaContext XMesaCreateContext( XMesaVisual v, XMesaContext share_list )
|
||||
if (!xmdpy)
|
||||
return NULL;
|
||||
|
||||
/* Note: the XMesaContext contains a Mesa GLcontext struct (inheritance) */
|
||||
/* Note: the XMesaContext contains a Mesa struct gl_context struct (inheritance) */
|
||||
c = (XMesaContext) CALLOC_STRUCT(xmesa_context);
|
||||
if (!c)
|
||||
return NULL;
|
||||
|
||||
@@ -30,12 +30,12 @@
|
||||
#include "ast.h"
|
||||
|
||||
extern "C" struct gl_shader *
|
||||
_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type);
|
||||
_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type);
|
||||
|
||||
gl_shader *
|
||||
read_builtins(GLenum target, const char *protos, const char **functions, unsigned count)
|
||||
{
|
||||
GLcontext fakeCtx;
|
||||
struct gl_context fakeCtx;
|
||||
fakeCtx.API = API_OPENGL;
|
||||
gl_shader *sh = _mesa_new_shader(NULL, 0, target);
|
||||
struct _mesa_glsl_parse_state *st =
|
||||
|
||||
@@ -123,12 +123,12 @@ if __name__ == "__main__":
|
||||
#include "ast.h"
|
||||
|
||||
extern "C" struct gl_shader *
|
||||
_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type);
|
||||
_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type);
|
||||
|
||||
gl_shader *
|
||||
read_builtins(GLenum target, const char *protos, const char **functions, unsigned count)
|
||||
{
|
||||
GLcontext fakeCtx;
|
||||
struct gl_context fakeCtx;
|
||||
fakeCtx.API = API_OPENGL;
|
||||
gl_shader *sh = _mesa_new_shader(NULL, 0, target);
|
||||
struct _mesa_glsl_parse_state *st =
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
extern "C" {
|
||||
#include <talloc.h>
|
||||
#include "main/core.h" /* for struct __GLcontextRec */
|
||||
#include "main/core.h" /* for struct gl_context */
|
||||
}
|
||||
|
||||
#include "ast.h"
|
||||
@@ -36,7 +36,7 @@ extern "C" {
|
||||
#include "ir_optimization.h"
|
||||
#include "loop_analysis.h"
|
||||
|
||||
_mesa_glsl_parse_state::_mesa_glsl_parse_state(struct __GLcontextRec *ctx,
|
||||
_mesa_glsl_parse_state::_mesa_glsl_parse_state(struct gl_context *ctx,
|
||||
GLenum target, void *mem_ctx)
|
||||
{
|
||||
switch (target) {
|
||||
|
||||
@@ -41,10 +41,10 @@ enum _mesa_glsl_parser_targets {
|
||||
ir_shader
|
||||
};
|
||||
|
||||
struct __GLcontextRec;
|
||||
struct gl_context;
|
||||
|
||||
struct _mesa_glsl_parse_state {
|
||||
_mesa_glsl_parse_state(struct __GLcontextRec *ctx, GLenum target,
|
||||
_mesa_glsl_parse_state(struct gl_context *ctx, GLenum target,
|
||||
void *mem_ctx);
|
||||
|
||||
/* Callers of this talloc-based new need not call delete. It's
|
||||
|
||||
+2
-2
@@ -719,7 +719,7 @@ get_main_function_signature(gl_shader *sh)
|
||||
* shader is returned.
|
||||
*/
|
||||
static struct gl_shader *
|
||||
link_intrastage_shaders(GLcontext *ctx,
|
||||
link_intrastage_shaders(struct gl_context *ctx,
|
||||
struct gl_shader_program *prog,
|
||||
struct gl_shader **shader_list,
|
||||
unsigned num_shaders)
|
||||
@@ -1386,7 +1386,7 @@ assign_varying_locations(struct gl_shader_program *prog,
|
||||
|
||||
|
||||
void
|
||||
link_shaders(GLcontext *ctx, struct gl_shader_program *prog)
|
||||
link_shaders(struct gl_context *ctx, struct gl_shader_program *prog)
|
||||
{
|
||||
prog->LinkStatus = false;
|
||||
prog->Validated = false;
|
||||
|
||||
+6
-6
@@ -38,12 +38,12 @@
|
||||
#include "loop_analysis.h"
|
||||
|
||||
extern "C" struct gl_shader *
|
||||
_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type);
|
||||
_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type);
|
||||
|
||||
/* Copied from shader_api.c for the stand-alone compiler.
|
||||
*/
|
||||
struct gl_shader *
|
||||
_mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type)
|
||||
_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type)
|
||||
{
|
||||
struct gl_shader *shader;
|
||||
|
||||
@@ -60,7 +60,7 @@ _mesa_new_shader(GLcontext *ctx, GLuint name, GLenum type)
|
||||
}
|
||||
|
||||
static void
|
||||
initialize_context(GLcontext *ctx, gl_api api)
|
||||
initialize_context(struct gl_context *ctx, gl_api api)
|
||||
{
|
||||
memset(ctx, 0, sizeof(*ctx));
|
||||
|
||||
@@ -160,7 +160,7 @@ const struct option compiler_opts[] = {
|
||||
};
|
||||
|
||||
void
|
||||
compile_shader(GLcontext *ctx, struct gl_shader *shader)
|
||||
compile_shader(struct gl_context *ctx, struct gl_shader *shader)
|
||||
{
|
||||
struct _mesa_glsl_parse_state *state =
|
||||
new(shader) _mesa_glsl_parse_state(ctx, shader->Type, shader);
|
||||
@@ -252,8 +252,8 @@ int
|
||||
main(int argc, char **argv)
|
||||
{
|
||||
int status = EXIT_SUCCESS;
|
||||
GLcontext local_ctx;
|
||||
GLcontext *ctx = &local_ctx;
|
||||
struct gl_context local_ctx;
|
||||
struct gl_context *ctx = &local_ctx;
|
||||
|
||||
int c;
|
||||
int idx = 0;
|
||||
|
||||
+1
-1
@@ -24,4 +24,4 @@
|
||||
#include "main/core.h"
|
||||
|
||||
extern void
|
||||
link_shaders(GLcontext *ctx, struct gl_shader_program *prog);
|
||||
link_shaders(struct gl_context *ctx, struct gl_shader_program *prog);
|
||||
|
||||
@@ -95,7 +95,7 @@ _GLAPI_EXPORT extern const struct _glapi_table *_glapi_Dispatch;
|
||||
_GLAPI_EXPORT extern const void *_glapi_Context;
|
||||
|
||||
# define GET_DISPATCH() _glapi_tls_Dispatch
|
||||
# define GET_CURRENT_CONTEXT(C) GLcontext *C = (GLcontext *) _glapi_tls_Context
|
||||
# define GET_CURRENT_CONTEXT(C) struct gl_context *C = (struct gl_context *) _glapi_tls_Context
|
||||
|
||||
#else
|
||||
|
||||
@@ -107,13 +107,13 @@ _GLAPI_EXPORT extern void *_glapi_Context;
|
||||
# define GET_DISPATCH() \
|
||||
(likely(_glapi_Dispatch) ? _glapi_Dispatch : _glapi_get_dispatch())
|
||||
|
||||
# define GET_CURRENT_CONTEXT(C) GLcontext *C = (GLcontext *) \
|
||||
# define GET_CURRENT_CONTEXT(C) struct gl_context *C = (struct gl_context *) \
|
||||
(likely(_glapi_Context) ? _glapi_Context : _glapi_get_context())
|
||||
|
||||
# else
|
||||
|
||||
# define GET_DISPATCH() _glapi_Dispatch
|
||||
# define GET_CURRENT_CONTEXT(C) GLcontext *C = (GLcontext *) _glapi_Context
|
||||
# define GET_CURRENT_CONTEXT(C) struct gl_context *C = (struct gl_context *) _glapi_Context
|
||||
|
||||
# endif
|
||||
|
||||
|
||||
@@ -105,7 +105,7 @@ public:
|
||||
MesaDriver();
|
||||
~MesaDriver();
|
||||
|
||||
void Init(BGLView * bglview, GLcontext * c, struct gl_config * v, struct gl_framebuffer * b);
|
||||
void Init(BGLView * bglview, struct gl_context * c, struct gl_config * v, struct gl_framebuffer * b);
|
||||
|
||||
void LockGL();
|
||||
void UnlockGL();
|
||||
@@ -120,7 +120,7 @@ private:
|
||||
MesaDriver(const MesaDriver &rhs); // copy constructor illegal
|
||||
MesaDriver &operator=(const MesaDriver &rhs); // assignment oper. illegal
|
||||
|
||||
GLcontext * m_glcontext;
|
||||
struct gl_context * m_glcontext;
|
||||
struct gl_config * m_glvisual;
|
||||
struct gl_framebuffer * m_glframebuffer;
|
||||
|
||||
@@ -134,119 +134,119 @@ private:
|
||||
GLuint m_height;
|
||||
|
||||
// Mesa Device Driver callback functions
|
||||
static void UpdateState(GLcontext *ctx, GLuint new_state);
|
||||
static void ClearIndex(GLcontext *ctx, GLuint index);
|
||||
static void ClearColor(GLcontext *ctx, const GLfloat color[4]);
|
||||
static void Clear(GLcontext *ctx, GLbitfield mask,
|
||||
static void UpdateState(struct gl_context *ctx, GLuint new_state);
|
||||
static void ClearIndex(struct gl_context *ctx, GLuint index);
|
||||
static void ClearColor(struct gl_context *ctx, const GLfloat color[4]);
|
||||
static void Clear(struct gl_context *ctx, GLbitfield mask,
|
||||
GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height);
|
||||
static void ClearFront(GLcontext *ctx, GLboolean all, GLint x, GLint y,
|
||||
static void ClearFront(struct gl_context *ctx, GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height);
|
||||
static void ClearBack(GLcontext *ctx, GLboolean all, GLint x, GLint y,
|
||||
static void ClearBack(struct gl_context *ctx, GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height);
|
||||
static void Index(GLcontext *ctx, GLuint index);
|
||||
static void Color(GLcontext *ctx, GLubyte r, GLubyte g,
|
||||
static void Index(struct gl_context *ctx, GLuint index);
|
||||
static void Color(struct gl_context *ctx, GLubyte r, GLubyte g,
|
||||
GLubyte b, GLubyte a);
|
||||
static void SetBuffer(GLcontext *ctx, struct gl_framebuffer *colorBuffer,
|
||||
static void SetBuffer(struct gl_context *ctx, struct gl_framebuffer *colorBuffer,
|
||||
GLenum mode);
|
||||
static void GetBufferSize(struct gl_framebuffer * framebuffer, GLuint *width,
|
||||
GLuint *height);
|
||||
static void Error(GLcontext *ctx);
|
||||
static const GLubyte * GetString(GLcontext *ctx, GLenum name);
|
||||
static void Viewport(GLcontext *ctx, GLint x, GLint y, GLsizei w, GLsizei h);
|
||||
static void Error(struct gl_context *ctx);
|
||||
static const GLubyte * GetString(struct gl_context *ctx, GLenum name);
|
||||
static void Viewport(struct gl_context *ctx, GLint x, GLint y, GLsizei w, GLsizei h);
|
||||
|
||||
// Front-buffer functions
|
||||
static void WriteRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBASpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteRGBSpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBSpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][3],
|
||||
const GLubyte mask[]);
|
||||
static void WriteMonoRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoRGBASpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteRGBAPixelsFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBAPixelsFront(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteMonoRGBAPixelsFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoRGBAPixelsFront(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteCI32SpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteCI32SpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLuint index[], const GLubyte mask[]);
|
||||
static void WriteCI8SpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteCI8SpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLubyte index[], const GLubyte mask[]);
|
||||
static void WriteMonoCISpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoCISpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
GLuint colorIndex, const GLubyte mask[]);
|
||||
static void WriteCI32PixelsFront(const GLcontext *ctx,
|
||||
static void WriteCI32PixelsFront(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
const GLuint index[], const GLubyte mask[]);
|
||||
static void WriteMonoCIPixelsFront(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoCIPixelsFront(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
GLuint colorIndex, const GLubyte mask[]);
|
||||
static void ReadCI32SpanFront(const GLcontext *ctx,
|
||||
static void ReadCI32SpanFront(const struct gl_context *ctx,
|
||||
GLuint n, GLint x, GLint y, GLuint index[]);
|
||||
static void ReadRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
static void ReadRGBASpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
GLubyte rgba[][4]);
|
||||
static void ReadCI32PixelsFront(const GLcontext *ctx,
|
||||
static void ReadCI32PixelsFront(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLuint indx[], const GLubyte mask[]);
|
||||
static void ReadRGBAPixelsFront(const GLcontext *ctx,
|
||||
static void ReadRGBAPixelsFront(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLubyte rgba[][4], const GLubyte mask[]);
|
||||
|
||||
// Back buffer functions
|
||||
static void WriteRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBASpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteRGBSpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBSpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][3],
|
||||
const GLubyte mask[]);
|
||||
static void WriteMonoRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoRGBASpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteRGBAPixelsBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteRGBAPixelsBack(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteMonoRGBAPixelsBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoRGBAPixelsBack(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[]);
|
||||
static void WriteCI32SpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteCI32SpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLuint index[], const GLubyte mask[]);
|
||||
static void WriteCI8SpanBack(const GLcontext *ctx, GLuint n, GLint x, GLint y,
|
||||
static void WriteCI8SpanBack(const struct gl_context *ctx, GLuint n, GLint x, GLint y,
|
||||
const GLubyte index[], const GLubyte mask[]);
|
||||
static void WriteMonoCISpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void WriteMonoCISpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y, GLuint colorIndex,
|
||||
const GLubyte mask[]);
|
||||
static void WriteCI32PixelsBack(const GLcontext *ctx,
|
||||
static void WriteCI32PixelsBack(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
const GLuint index[], const GLubyte mask[]);
|
||||
static void WriteMonoCIPixelsBack(const GLcontext *ctx,
|
||||
static void WriteMonoCIPixelsBack(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLuint colorIndex, const GLubyte mask[]);
|
||||
static void ReadCI32SpanBack(const GLcontext *ctx,
|
||||
static void ReadCI32SpanBack(const struct gl_context *ctx,
|
||||
GLuint n, GLint x, GLint y, GLuint index[]);
|
||||
static void ReadRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
static void ReadRGBASpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
GLubyte rgba[][4]);
|
||||
static void ReadCI32PixelsBack(const GLcontext *ctx,
|
||||
static void ReadCI32PixelsBack(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLuint indx[], const GLubyte mask[]);
|
||||
static void ReadRGBAPixelsBack(const GLcontext *ctx,
|
||||
static void ReadRGBAPixelsBack(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLubyte rgba[][4], const GLubyte mask[]);
|
||||
|
||||
@@ -319,7 +319,7 @@ BGLView::BGLView(BRect rect, char *name,
|
||||
functions.Viewport = md->Viewport;
|
||||
|
||||
// create core context
|
||||
GLcontext *ctx = _mesa_create_context(visual, NULL, &functions, md);
|
||||
struct gl_context *ctx = _mesa_create_context(visual, NULL, &functions, md);
|
||||
if (! ctx) {
|
||||
_mesa_destroy_visual(visual);
|
||||
delete md;
|
||||
@@ -668,7 +668,7 @@ MesaDriver::~MesaDriver()
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::Init(BGLView * bglview, GLcontext * ctx, struct gl_config * visual, struct gl_framebuffer * framebuffer)
|
||||
void MesaDriver::Init(BGLView * bglview, struct gl_context * ctx, struct gl_config * visual, struct gl_framebuffer * framebuffer)
|
||||
{
|
||||
m_bglview = bglview;
|
||||
m_glcontext = ctx;
|
||||
@@ -815,14 +815,14 @@ void MesaDriver::Draw(BRect updateRect) const
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::Error(GLcontext *ctx)
|
||||
void MesaDriver::Error(struct gl_context *ctx)
|
||||
{
|
||||
MesaDriver *md = (MesaDriver *) ctx->DriverCtx;
|
||||
if (md && md->m_bglview)
|
||||
md->m_bglview->ErrorCallback((unsigned long) ctx->ErrorValue);
|
||||
}
|
||||
|
||||
void MesaDriver::UpdateState( GLcontext *ctx, GLuint new_state )
|
||||
void MesaDriver::UpdateState( struct gl_context *ctx, GLuint new_state )
|
||||
{
|
||||
struct swrast_device_driver * swdd = _swrast_GetDeviceDriverReference( ctx );
|
||||
|
||||
@@ -868,14 +868,14 @@ void MesaDriver::UpdateState( GLcontext *ctx, GLuint new_state )
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ClearIndex(GLcontext *ctx, GLuint index)
|
||||
void MesaDriver::ClearIndex(struct gl_context *ctx, GLuint index)
|
||||
{
|
||||
MesaDriver *md = (MesaDriver *) ctx->DriverCtx;
|
||||
md->m_clear_index = index;
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ClearColor(GLcontext *ctx, const GLfloat color[4])
|
||||
void MesaDriver::ClearColor(struct gl_context *ctx, const GLfloat color[4])
|
||||
{
|
||||
MesaDriver *md = (MesaDriver *) ctx->DriverCtx;
|
||||
CLAMPED_FLOAT_TO_CHAN(md->m_clear_color[BE_RCOMP], color[0]);
|
||||
@@ -886,7 +886,7 @@ void MesaDriver::ClearColor(GLcontext *ctx, const GLfloat color[4])
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::Clear(GLcontext *ctx, GLbitfield mask,
|
||||
void MesaDriver::Clear(struct gl_context *ctx, GLbitfield mask,
|
||||
GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height)
|
||||
{
|
||||
@@ -903,7 +903,7 @@ void MesaDriver::Clear(GLcontext *ctx, GLbitfield mask,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ClearFront(GLcontext *ctx,
|
||||
void MesaDriver::ClearFront(struct gl_context *ctx,
|
||||
GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height)
|
||||
{
|
||||
@@ -947,7 +947,7 @@ void MesaDriver::ClearFront(GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ClearBack(GLcontext *ctx,
|
||||
void MesaDriver::ClearBack(struct gl_context *ctx,
|
||||
GLboolean all, GLint x, GLint y,
|
||||
GLint width, GLint height)
|
||||
{
|
||||
@@ -984,7 +984,7 @@ void MesaDriver::ClearBack(GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::SetBuffer(GLcontext *ctx, struct gl_framebuffer *buffer,
|
||||
void MesaDriver::SetBuffer(struct gl_context *ctx, struct gl_framebuffer *buffer,
|
||||
GLenum mode)
|
||||
{
|
||||
/* TODO */
|
||||
@@ -1028,14 +1028,14 @@ void MesaDriver::GetBufferSize(struct gl_framebuffer * framebuffer, GLuint *widt
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::Viewport(GLcontext *ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
void MesaDriver::Viewport(struct gl_context *ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
{
|
||||
/* poll for window size change and realloc software Z/stencil/etc if needed */
|
||||
_mesa_ResizeBuffersMESA();
|
||||
}
|
||||
|
||||
|
||||
const GLubyte *MesaDriver::GetString(GLcontext *ctx, GLenum name)
|
||||
const GLubyte *MesaDriver::GetString(struct gl_context *ctx, GLenum name)
|
||||
{
|
||||
switch (name) {
|
||||
case GL_RENDERER:
|
||||
@@ -1057,7 +1057,7 @@ inline void Plot(BGLView *bglview, int x, int y)
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteRGBASpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[])
|
||||
@@ -1082,7 +1082,7 @@ void MesaDriver::WriteRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
}
|
||||
|
||||
void MesaDriver::WriteRGBSpanFront(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteRGBSpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][3],
|
||||
const GLubyte mask[])
|
||||
@@ -1107,7 +1107,7 @@ void MesaDriver::WriteRGBSpanFront(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
}
|
||||
|
||||
void MesaDriver::WriteMonoRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoRGBASpanFront(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[])
|
||||
@@ -1131,7 +1131,7 @@ void MesaDriver::WriteMonoRGBASpanFront(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
}
|
||||
|
||||
void MesaDriver::WriteRGBAPixelsFront(const GLcontext *ctx,
|
||||
void MesaDriver::WriteRGBAPixelsFront(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[] )
|
||||
@@ -1156,7 +1156,7 @@ void MesaDriver::WriteRGBAPixelsFront(const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteMonoRGBAPixelsFront(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoRGBAPixelsFront(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[])
|
||||
@@ -1181,21 +1181,21 @@ void MesaDriver::WriteMonoRGBAPixelsFront(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteCI32SpanFront( const GLcontext *ctx, GLuint n, GLint x, GLint y,
|
||||
void MesaDriver::WriteCI32SpanFront( const struct gl_context *ctx, GLuint n, GLint x, GLint y,
|
||||
const GLuint index[], const GLubyte mask[] )
|
||||
{
|
||||
printf("WriteCI32SpanFront() not implemented yet!\n");
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteCI8SpanFront( const GLcontext *ctx, GLuint n, GLint x, GLint y,
|
||||
void MesaDriver::WriteCI8SpanFront( const struct gl_context *ctx, GLuint n, GLint x, GLint y,
|
||||
const GLubyte index[], const GLubyte mask[] )
|
||||
{
|
||||
printf("WriteCI8SpanFront() not implemented yet!\n");
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteMonoCISpanFront( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoCISpanFront( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
GLuint colorIndex, const GLubyte mask[] )
|
||||
{
|
||||
@@ -1204,7 +1204,7 @@ void MesaDriver::WriteMonoCISpanFront( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteCI32PixelsFront( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteCI32PixelsFront( const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLuint index[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1212,7 +1212,7 @@ void MesaDriver::WriteCI32PixelsFront( const GLcontext *ctx, GLuint n,
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteMonoCIPixelsFront( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoCIPixelsFront( const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
GLuint colorIndex, const GLubyte mask[] )
|
||||
{
|
||||
@@ -1221,7 +1221,7 @@ void MesaDriver::WriteMonoCIPixelsFront( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadCI32SpanFront( const GLcontext *ctx,
|
||||
void MesaDriver::ReadCI32SpanFront( const struct gl_context *ctx,
|
||||
GLuint n, GLint x, GLint y, GLuint index[] )
|
||||
{
|
||||
printf("ReadCI32SpanFront() not implemented yet!\n");
|
||||
@@ -1229,7 +1229,7 @@ void MesaDriver::ReadCI32SpanFront( const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadRGBASpanFront( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::ReadRGBASpanFront( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y, GLubyte rgba[][4] )
|
||||
{
|
||||
printf("ReadRGBASpanFront() not implemented yet!\n");
|
||||
@@ -1237,7 +1237,7 @@ void MesaDriver::ReadRGBASpanFront( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadCI32PixelsFront( const GLcontext *ctx,
|
||||
void MesaDriver::ReadCI32PixelsFront( const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLuint indx[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1246,7 +1246,7 @@ void MesaDriver::ReadCI32PixelsFront( const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadRGBAPixelsFront( const GLcontext *ctx,
|
||||
void MesaDriver::ReadRGBAPixelsFront( const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLubyte rgba[][4], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1257,7 +1257,7 @@ void MesaDriver::ReadRGBAPixelsFront( const GLcontext *ctx,
|
||||
|
||||
|
||||
|
||||
void MesaDriver::WriteRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteRGBASpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[])
|
||||
@@ -1287,7 +1287,7 @@ void MesaDriver::WriteRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteRGBSpanBack(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteRGBSpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
CONST GLubyte rgb[][3],
|
||||
const GLubyte mask[])
|
||||
@@ -1319,7 +1319,7 @@ void MesaDriver::WriteRGBSpanBack(const GLcontext *ctx, GLuint n,
|
||||
|
||||
|
||||
|
||||
void MesaDriver::WriteMonoRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoRGBASpanBack(const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLchan color[4], const GLubyte mask[])
|
||||
{
|
||||
@@ -1347,7 +1347,7 @@ void MesaDriver::WriteMonoRGBASpanBack(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteRGBAPixelsBack(const GLcontext *ctx,
|
||||
void MesaDriver::WriteRGBAPixelsBack(const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
CONST GLubyte rgba[][4],
|
||||
const GLubyte mask[] )
|
||||
@@ -1394,7 +1394,7 @@ void MesaDriver::WriteRGBAPixelsBack(const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteMonoRGBAPixelsBack(const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoRGBAPixelsBack(const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLchan color[4],
|
||||
const GLubyte mask[])
|
||||
@@ -1437,7 +1437,7 @@ void MesaDriver::WriteMonoRGBAPixelsBack(const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteCI32SpanBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteCI32SpanBack( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLuint index[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1445,7 +1445,7 @@ void MesaDriver::WriteCI32SpanBack( const GLcontext *ctx, GLuint n,
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteCI8SpanBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteCI8SpanBack( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
const GLubyte index[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1453,7 +1453,7 @@ void MesaDriver::WriteCI8SpanBack( const GLcontext *ctx, GLuint n,
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteMonoCISpanBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoCISpanBack( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y,
|
||||
GLuint colorIndex, const GLubyte mask[] )
|
||||
{
|
||||
@@ -1462,7 +1462,7 @@ void MesaDriver::WriteMonoCISpanBack( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::WriteCI32PixelsBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteCI32PixelsBack( const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
const GLuint index[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1470,7 +1470,7 @@ void MesaDriver::WriteCI32PixelsBack( const GLcontext *ctx, GLuint n,
|
||||
// TODO
|
||||
}
|
||||
|
||||
void MesaDriver::WriteMonoCIPixelsBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::WriteMonoCIPixelsBack( const struct gl_context *ctx, GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
GLuint colorIndex, const GLubyte mask[] )
|
||||
{
|
||||
@@ -1479,7 +1479,7 @@ void MesaDriver::WriteMonoCIPixelsBack( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadCI32SpanBack( const GLcontext *ctx,
|
||||
void MesaDriver::ReadCI32SpanBack( const struct gl_context *ctx,
|
||||
GLuint n, GLint x, GLint y, GLuint index[] )
|
||||
{
|
||||
printf("ReadCI32SpanBack() not implemented yet!\n");
|
||||
@@ -1487,7 +1487,7 @@ void MesaDriver::ReadCI32SpanBack( const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadRGBASpanBack( const GLcontext *ctx, GLuint n,
|
||||
void MesaDriver::ReadRGBASpanBack( const struct gl_context *ctx, GLuint n,
|
||||
GLint x, GLint y, GLubyte rgba[][4] )
|
||||
{
|
||||
MesaDriver *md = (MesaDriver *) ctx->DriverCtx;
|
||||
@@ -1507,7 +1507,7 @@ void MesaDriver::ReadRGBASpanBack( const GLcontext *ctx, GLuint n,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadCI32PixelsBack( const GLcontext *ctx,
|
||||
void MesaDriver::ReadCI32PixelsBack( const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLuint indx[], const GLubyte mask[] )
|
||||
{
|
||||
@@ -1516,7 +1516,7 @@ void MesaDriver::ReadCI32PixelsBack( const GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
void MesaDriver::ReadRGBAPixelsBack( const GLcontext *ctx,
|
||||
void MesaDriver::ReadRGBAPixelsBack( const struct gl_context *ctx,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
GLubyte rgba[][4], const GLubyte mask[] )
|
||||
{
|
||||
|
||||
@@ -224,7 +224,7 @@ _mesa_init_driver_functions(struct dd_function_table *driver)
|
||||
* Only the Intel drivers use this so far.
|
||||
*/
|
||||
void
|
||||
_mesa_init_driver_state(GLcontext *ctx)
|
||||
_mesa_init_driver_state(struct gl_context *ctx)
|
||||
{
|
||||
ctx->Driver.AlphaFunc(ctx, ctx->Color.AlphaFunc, ctx->Color.AlphaRef);
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ _mesa_init_driver_functions(struct dd_function_table *driver);
|
||||
|
||||
|
||||
extern void
|
||||
_mesa_init_driver_state(GLcontext *ctx);
|
||||
_mesa_init_driver_state(struct gl_context *ctx);
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -284,7 +284,7 @@ struct gl_meta_state
|
||||
* To be called once during context creation.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_init(GLcontext *ctx)
|
||||
_mesa_meta_init(struct gl_context *ctx)
|
||||
{
|
||||
ASSERT(!ctx->Meta);
|
||||
|
||||
@@ -297,7 +297,7 @@ _mesa_meta_init(GLcontext *ctx)
|
||||
* To be called once during context destruction.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_free(GLcontext *ctx)
|
||||
_mesa_meta_free(struct gl_context *ctx)
|
||||
{
|
||||
/* Note: Any textures, VBOs, etc, that we allocate should get
|
||||
* freed by the normal context destruction code. But this would be
|
||||
@@ -316,7 +316,7 @@ _mesa_meta_free(GLcontext *ctx)
|
||||
* to save and reset to their defaults
|
||||
*/
|
||||
static void
|
||||
_mesa_meta_begin(GLcontext *ctx, GLbitfield state)
|
||||
_mesa_meta_begin(struct gl_context *ctx, GLbitfield state)
|
||||
{
|
||||
struct save_state *save = &ctx->Meta->Save;
|
||||
|
||||
@@ -557,7 +557,7 @@ _mesa_meta_begin(GLcontext *ctx, GLbitfield state)
|
||||
* Leave meta state. This is like a light-weight version of glPopAttrib().
|
||||
*/
|
||||
static void
|
||||
_mesa_meta_end(GLcontext *ctx)
|
||||
_mesa_meta_end(struct gl_context *ctx)
|
||||
{
|
||||
struct save_state *save = &ctx->Meta->Save;
|
||||
const GLbitfield state = save->SavedState;
|
||||
@@ -824,7 +824,7 @@ invert_z(GLfloat normZ)
|
||||
* Choose tex target, compute max tex size, etc.
|
||||
*/
|
||||
static void
|
||||
init_temp_texture(GLcontext *ctx, struct temp_texture *tex)
|
||||
init_temp_texture(struct gl_context *ctx, struct temp_texture *tex)
|
||||
{
|
||||
/* prefer texture rectangle */
|
||||
if (ctx->Extensions.NV_texture_rectangle) {
|
||||
@@ -850,7 +850,7 @@ init_temp_texture(GLcontext *ctx, struct temp_texture *tex)
|
||||
* This does some one-time init if needed.
|
||||
*/
|
||||
static struct temp_texture *
|
||||
get_temp_texture(GLcontext *ctx)
|
||||
get_temp_texture(struct gl_context *ctx)
|
||||
{
|
||||
struct temp_texture *tex = &ctx->Meta->TempTex;
|
||||
|
||||
@@ -868,7 +868,7 @@ get_temp_texture(GLcontext *ctx)
|
||||
* allocation/deallocation.
|
||||
*/
|
||||
static struct temp_texture *
|
||||
get_bitmap_temp_texture(GLcontext *ctx)
|
||||
get_bitmap_temp_texture(struct gl_context *ctx)
|
||||
{
|
||||
struct temp_texture *tex = &ctx->Meta->Bitmap.Tex;
|
||||
|
||||
@@ -984,7 +984,7 @@ setup_copypix_texture(struct temp_texture *tex,
|
||||
* Setup/load texture for glDrawPixels.
|
||||
*/
|
||||
static void
|
||||
setup_drawpix_texture(GLcontext *ctx,
|
||||
setup_drawpix_texture(struct gl_context *ctx,
|
||||
struct temp_texture *tex,
|
||||
GLboolean newTex,
|
||||
GLenum texIntFormat,
|
||||
@@ -1035,7 +1035,7 @@ setup_drawpix_texture(GLcontext *ctx,
|
||||
* One-time init for drawing depth pixels.
|
||||
*/
|
||||
static void
|
||||
init_blit_depth_pixels(GLcontext *ctx)
|
||||
init_blit_depth_pixels(struct gl_context *ctx)
|
||||
{
|
||||
static const char *program =
|
||||
"!!ARBfp1.0\n"
|
||||
@@ -1072,7 +1072,7 @@ init_blit_depth_pixels(GLcontext *ctx)
|
||||
* normal path.
|
||||
*/
|
||||
static GLbitfield
|
||||
blitframebuffer_texture(GLcontext *ctx,
|
||||
blitframebuffer_texture(struct gl_context *ctx,
|
||||
GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
|
||||
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
|
||||
GLbitfield mask, GLenum filter)
|
||||
@@ -1201,7 +1201,7 @@ blitframebuffer_texture(GLcontext *ctx,
|
||||
* of texture mapping and polygon rendering.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_BlitFramebuffer(GLcontext *ctx,
|
||||
_mesa_meta_BlitFramebuffer(struct gl_context *ctx,
|
||||
GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
|
||||
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
|
||||
GLbitfield mask, GLenum filter)
|
||||
@@ -1362,7 +1362,7 @@ _mesa_meta_BlitFramebuffer(GLcontext *ctx,
|
||||
* Meta implementation of ctx->Driver.Clear() in terms of polygon rendering.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_Clear(GLcontext *ctx, GLbitfield buffers)
|
||||
_mesa_meta_Clear(struct gl_context *ctx, GLbitfield buffers)
|
||||
{
|
||||
struct clear_state *clear = &ctx->Meta->Clear;
|
||||
struct vertex {
|
||||
@@ -1480,7 +1480,7 @@ _mesa_meta_Clear(GLcontext *ctx, GLbitfield buffers)
|
||||
* of texture mapping and polygon rendering.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_CopyPixels(GLcontext *ctx, GLint srcX, GLint srcY,
|
||||
_mesa_meta_CopyPixels(struct gl_context *ctx, GLint srcX, GLint srcY,
|
||||
GLsizei width, GLsizei height,
|
||||
GLint dstX, GLint dstY, GLenum type)
|
||||
{
|
||||
@@ -1594,7 +1594,7 @@ _mesa_meta_CopyPixels(GLcontext *ctx, GLint srcX, GLint srcY,
|
||||
* into tiles which fit into the max texture size.
|
||||
*/
|
||||
static void
|
||||
tiled_draw_pixels(GLcontext *ctx,
|
||||
tiled_draw_pixels(struct gl_context *ctx,
|
||||
GLint tileSize,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height,
|
||||
GLenum format, GLenum type,
|
||||
@@ -1630,7 +1630,7 @@ tiled_draw_pixels(GLcontext *ctx,
|
||||
* One-time init for drawing stencil pixels.
|
||||
*/
|
||||
static void
|
||||
init_draw_stencil_pixels(GLcontext *ctx)
|
||||
init_draw_stencil_pixels(struct gl_context *ctx)
|
||||
{
|
||||
/* This program is run eight times, once for each stencil bit.
|
||||
* The stencil values to draw are found in an 8-bit alpha texture.
|
||||
@@ -1694,7 +1694,7 @@ init_draw_stencil_pixels(GLcontext *ctx)
|
||||
* One-time init for drawing depth pixels.
|
||||
*/
|
||||
static void
|
||||
init_draw_depth_pixels(GLcontext *ctx)
|
||||
init_draw_depth_pixels(struct gl_context *ctx)
|
||||
{
|
||||
static const char *program =
|
||||
"!!ARBfp1.0\n"
|
||||
@@ -1729,7 +1729,7 @@ init_draw_depth_pixels(GLcontext *ctx)
|
||||
* of texture mapping and polygon rendering.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_DrawPixels(GLcontext *ctx,
|
||||
_mesa_meta_DrawPixels(struct gl_context *ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height,
|
||||
GLenum format, GLenum type,
|
||||
const struct gl_pixelstore_attrib *unpack,
|
||||
@@ -1962,7 +1962,7 @@ _mesa_meta_DrawPixels(GLcontext *ctx,
|
||||
* improve performance a lot.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_Bitmap(GLcontext *ctx,
|
||||
_mesa_meta_Bitmap(struct gl_context *ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height,
|
||||
const struct gl_pixelstore_attrib *unpack,
|
||||
const GLubyte *bitmap1)
|
||||
@@ -2111,7 +2111,7 @@ _mesa_meta_Bitmap(GLcontext *ctx,
|
||||
* \return GL_TRUE if a fallback is needed, GL_FALSE otherwise
|
||||
*/
|
||||
GLboolean
|
||||
_mesa_meta_check_generate_mipmap_fallback(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_check_generate_mipmap_fallback(struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *texObj)
|
||||
{
|
||||
const GLuint fboSave = ctx->DrawBuffer->Name;
|
||||
@@ -2177,7 +2177,7 @@ _mesa_meta_check_generate_mipmap_fallback(GLcontext *ctx, GLenum target,
|
||||
* Note: texture borders and 3D texture support not yet complete.
|
||||
*/
|
||||
void
|
||||
_mesa_meta_GenerateMipmap(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *texObj)
|
||||
{
|
||||
struct gen_mipmap_state *mipmap = &ctx->Meta->Mipmap;
|
||||
@@ -2494,7 +2494,7 @@ _mesa_meta_GenerateMipmap(GLcontext *ctx, GLenum target,
|
||||
* ReadPixels() and passed to Tex[Sub]Image().
|
||||
*/
|
||||
static GLenum
|
||||
get_temp_image_type(GLcontext *ctx, GLenum baseFormat)
|
||||
get_temp_image_type(struct gl_context *ctx, GLenum baseFormat)
|
||||
{
|
||||
switch (baseFormat) {
|
||||
case GL_RGBA:
|
||||
@@ -2525,7 +2525,7 @@ get_temp_image_type(GLcontext *ctx, GLenum baseFormat)
|
||||
* Have to be careful with locking and meta state for pixel transfer.
|
||||
*/
|
||||
static void
|
||||
copy_tex_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
|
||||
copy_tex_image(struct gl_context *ctx, GLuint dims, GLenum target, GLint level,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLsizei height, GLint border)
|
||||
{
|
||||
@@ -2603,7 +2603,7 @@ copy_tex_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyTexImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexImage1D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLint border)
|
||||
{
|
||||
@@ -2613,7 +2613,7 @@ _mesa_meta_CopyTexImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyTexImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexImage2D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLsizei height, GLint border)
|
||||
{
|
||||
@@ -2628,7 +2628,7 @@ _mesa_meta_CopyTexImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
* Have to be careful with locking and meta state for pixel transfer.
|
||||
*/
|
||||
static void
|
||||
copy_tex_sub_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
|
||||
copy_tex_sub_image(struct gl_context *ctx, GLuint dims, GLenum target, GLint level,
|
||||
GLint xoffset, GLint yoffset, GLint zoffset,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height)
|
||||
@@ -2699,7 +2699,7 @@ copy_tex_sub_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyTexSubImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset,
|
||||
GLint x, GLint y, GLsizei width)
|
||||
{
|
||||
@@ -2709,7 +2709,7 @@ _mesa_meta_CopyTexSubImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyTexSubImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset, GLint yoffset,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height)
|
||||
@@ -2720,7 +2720,7 @@ _mesa_meta_CopyTexSubImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyTexSubImage3D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset, GLint yoffset, GLint zoffset,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height)
|
||||
@@ -2731,7 +2731,7 @@ _mesa_meta_CopyTexSubImage3D(GLcontext *ctx, GLenum target, GLint level,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyColorTable(GLcontext *ctx,
|
||||
_mesa_meta_CopyColorTable(struct gl_context *ctx,
|
||||
GLenum target, GLenum internalformat,
|
||||
GLint x, GLint y, GLsizei width)
|
||||
{
|
||||
@@ -2759,7 +2759,7 @@ _mesa_meta_CopyColorTable(GLcontext *ctx,
|
||||
|
||||
|
||||
void
|
||||
_mesa_meta_CopyColorSubTable(GLcontext *ctx,GLenum target, GLsizei start,
|
||||
_mesa_meta_CopyColorSubTable(struct gl_context *ctx,GLenum target, GLsizei start,
|
||||
GLint x, GLint y, GLsizei width)
|
||||
{
|
||||
GLfloat *buf;
|
||||
|
||||
@@ -28,89 +28,89 @@
|
||||
|
||||
|
||||
extern void
|
||||
_mesa_meta_init(GLcontext *ctx);
|
||||
_mesa_meta_init(struct gl_context *ctx);
|
||||
|
||||
extern void
|
||||
_mesa_meta_free(GLcontext *ctx);
|
||||
_mesa_meta_free(struct gl_context *ctx);
|
||||
|
||||
extern void
|
||||
_mesa_meta_BlitFramebuffer(GLcontext *ctx,
|
||||
_mesa_meta_BlitFramebuffer(struct gl_context *ctx,
|
||||
GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
|
||||
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
|
||||
GLbitfield mask, GLenum filter);
|
||||
|
||||
extern void
|
||||
_mesa_meta_Clear(GLcontext *ctx, GLbitfield buffers);
|
||||
_mesa_meta_Clear(struct gl_context *ctx, GLbitfield buffers);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyPixels(GLcontext *ctx, GLint srcx, GLint srcy,
|
||||
_mesa_meta_CopyPixels(struct gl_context *ctx, GLint srcx, GLint srcy,
|
||||
GLsizei width, GLsizei height,
|
||||
GLint dstx, GLint dsty, GLenum type);
|
||||
|
||||
extern void
|
||||
_mesa_meta_DrawPixels(GLcontext *ctx,
|
||||
_mesa_meta_DrawPixels(struct gl_context *ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height,
|
||||
GLenum format, GLenum type,
|
||||
const struct gl_pixelstore_attrib *unpack,
|
||||
const GLvoid *pixels);
|
||||
|
||||
extern void
|
||||
_mesa_meta_Bitmap(GLcontext *ctx,
|
||||
_mesa_meta_Bitmap(struct gl_context *ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height,
|
||||
const struct gl_pixelstore_attrib *unpack,
|
||||
const GLubyte *bitmap);
|
||||
|
||||
extern GLboolean
|
||||
_mesa_meta_check_generate_mipmap_fallback(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_check_generate_mipmap_fallback(struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *texObj);
|
||||
|
||||
extern void
|
||||
_mesa_meta_GenerateMipmap(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *texObj);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyTexImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexImage1D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLint border);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyTexImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexImage2D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLsizei height, GLint border);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyTexSubImage1D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage1D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset,
|
||||
GLint x, GLint y, GLsizei width);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyTexSubImage2D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage2D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset, GLint yoffset,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyTexSubImage3D(GLcontext *ctx, GLenum target, GLint level,
|
||||
_mesa_meta_CopyTexSubImage3D(struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint xoffset, GLint yoffset, GLint zoffset,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyColorTable(GLcontext *ctx,
|
||||
_mesa_meta_CopyColorTable(struct gl_context *ctx,
|
||||
GLenum target, GLenum internalformat,
|
||||
GLint x, GLint y, GLsizei width);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyColorSubTable(GLcontext *ctx,GLenum target, GLsizei start,
|
||||
_mesa_meta_CopyColorSubTable(struct gl_context *ctx,GLenum target, GLsizei start,
|
||||
GLint x, GLint y, GLsizei width);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyConvolutionFilter1D(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_CopyConvolutionFilter1D(struct gl_context *ctx, GLenum target,
|
||||
GLenum internalFormat,
|
||||
GLint x, GLint y, GLsizei width);
|
||||
|
||||
extern void
|
||||
_mesa_meta_CopyConvolutionFilter2D(GLcontext *ctx, GLenum target,
|
||||
_mesa_meta_CopyConvolutionFilter2D(struct gl_context *ctx, GLenum target,
|
||||
GLenum internalFormat, GLint x, GLint y,
|
||||
GLsizei width, GLsizei height);
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
#define HAVE_HW_DEPTH_PIXELS 0
|
||||
#endif
|
||||
|
||||
static void TAG(WriteDepthSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteDepthSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values,
|
||||
@@ -72,7 +72,7 @@ static void TAG(WriteDepthSpan)( GLcontext *ctx,
|
||||
#if HAVE_HW_DEPTH_SPANS
|
||||
/* implement MonoWriteDepthSpan() in terms of WriteDepthSpan() */
|
||||
static void
|
||||
TAG(WriteMonoDepthSpan)( GLcontext *ctx, struct gl_renderbuffer *rb,
|
||||
TAG(WriteMonoDepthSpan)( struct gl_context *ctx, struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value, const GLubyte mask[] )
|
||||
{
|
||||
@@ -84,7 +84,7 @@ TAG(WriteMonoDepthSpan)( GLcontext *ctx, struct gl_renderbuffer *rb,
|
||||
TAG(WriteDepthSpan)(ctx, rb, n, x, y, depths, mask);
|
||||
}
|
||||
#else
|
||||
static void TAG(WriteMonoDepthSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoDepthSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value,
|
||||
@@ -124,7 +124,7 @@ static void TAG(WriteMonoDepthSpan)( GLcontext *ctx,
|
||||
#endif
|
||||
|
||||
|
||||
static void TAG(WriteDepthPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteDepthPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n,
|
||||
const GLint x[],
|
||||
@@ -173,7 +173,7 @@ static void TAG(WriteDepthPixels)( GLcontext *ctx,
|
||||
|
||||
/* Read depth spans and pixels
|
||||
*/
|
||||
static void TAG(ReadDepthSpan)( GLcontext *ctx,
|
||||
static void TAG(ReadDepthSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
void *values )
|
||||
@@ -207,7 +207,7 @@ static void TAG(ReadDepthSpan)( GLcontext *ctx,
|
||||
HW_READ_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(ReadDepthPixels)( GLcontext *ctx,
|
||||
static void TAG(ReadDepthPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
void
|
||||
meta_set_passthrough_transform(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
|
||||
meta->saved_vp_x = ctx->Viewport.X;
|
||||
meta->saved_vp_y = ctx->Viewport.Y;
|
||||
@@ -87,7 +87,7 @@ meta_restore_transform(struct dri_metaops *meta)
|
||||
void
|
||||
meta_set_passthrough_vertex_program(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
static const char *vp =
|
||||
"!!ARBvp1.0\n"
|
||||
"TEMP vertexClip;\n"
|
||||
@@ -133,7 +133,7 @@ meta_set_passthrough_vertex_program(struct dri_metaops *meta)
|
||||
void
|
||||
meta_restore_vertex_program(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
|
||||
FLUSH_VERTICES(ctx, _NEW_PROGRAM);
|
||||
_mesa_reference_vertprog(ctx, &ctx->VertexProgram.Current,
|
||||
@@ -155,7 +155,7 @@ meta_set_fragment_program(struct dri_metaops *meta,
|
||||
struct gl_fragment_program **prog,
|
||||
const char *prog_string)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
assert(meta->saved_fp == NULL);
|
||||
|
||||
_mesa_reference_fragprog(ctx, &meta->saved_fp,
|
||||
@@ -187,7 +187,7 @@ meta_set_fragment_program(struct dri_metaops *meta,
|
||||
void
|
||||
meta_restore_fragment_program(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
|
||||
FLUSH_VERTICES(ctx, _NEW_PROGRAM);
|
||||
_mesa_reference_fragprog(ctx, &ctx->FragmentProgram.Current,
|
||||
@@ -208,7 +208,7 @@ static const float default_texcoords[4][2] = { { 0.0, 0.0 },
|
||||
void
|
||||
meta_set_default_texrect(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
struct gl_client_array *old_texcoord_array;
|
||||
|
||||
meta->saved_active_texture = ctx->Texture.CurrentUnit;
|
||||
@@ -249,7 +249,7 @@ meta_set_default_texrect(struct dri_metaops *meta)
|
||||
void
|
||||
meta_restore_texcoords(struct dri_metaops *meta)
|
||||
{
|
||||
GLcontext *ctx = meta->ctx;
|
||||
struct gl_context *ctx = meta->ctx;
|
||||
|
||||
/* Restore the old TexCoordPointer */
|
||||
if (meta->saved_texcoord_vbo) {
|
||||
@@ -280,7 +280,7 @@ meta_restore_texcoords(struct dri_metaops *meta)
|
||||
}
|
||||
|
||||
|
||||
void meta_init_metaops(GLcontext *ctx, struct dri_metaops *meta)
|
||||
void meta_init_metaops(struct gl_context *ctx, struct dri_metaops *meta)
|
||||
{
|
||||
meta->ctx = ctx;
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
|
||||
struct dri_metaops {
|
||||
GLcontext *ctx;
|
||||
struct gl_context *ctx;
|
||||
GLboolean internal_viewport_call;
|
||||
struct gl_fragment_program *bitmap_fp;
|
||||
struct gl_vertex_program *passthrough_vp;
|
||||
@@ -75,7 +75,7 @@ void meta_set_default_texrect(struct dri_metaops *meta);
|
||||
|
||||
void meta_restore_texcoords(struct dri_metaops *meta);
|
||||
|
||||
void meta_init_metaops(GLcontext *ctx, struct dri_metaops *meta);
|
||||
void meta_init_metaops(struct gl_context *ctx, struct dri_metaops *meta);
|
||||
void meta_destroy_metaops(struct dri_metaops *meta);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
* be used.
|
||||
*/
|
||||
static GLboolean
|
||||
driRenderbufferStorage(GLcontext *ctx, struct gl_renderbuffer *rb,
|
||||
driRenderbufferStorage(struct gl_context *ctx, struct gl_renderbuffer *rb,
|
||||
GLenum internalFormat, GLuint width, GLuint height)
|
||||
{
|
||||
rb->Width = width;
|
||||
@@ -187,7 +187,7 @@ driFlipRenderbuffers(struct gl_framebuffer *fb, GLboolean flipped)
|
||||
* gl_framebuffer object.
|
||||
*/
|
||||
void
|
||||
driUpdateFramebufferSize(GLcontext *ctx, const __DRIdrawable *dPriv)
|
||||
driUpdateFramebufferSize(struct gl_context *ctx, const __DRIdrawable *dPriv)
|
||||
{
|
||||
struct gl_framebuffer *fb = (struct gl_framebuffer *) dPriv->driverPrivate;
|
||||
if (fb && (dPriv->w != fb->Width || dPriv->h != fb->Height)) {
|
||||
|
||||
@@ -73,7 +73,7 @@ driFlipRenderbuffers(struct gl_framebuffer *fb, GLboolean flipped);
|
||||
|
||||
|
||||
extern void
|
||||
driUpdateFramebufferSize(GLcontext *ctx, const __DRIdrawable *dPriv);
|
||||
driUpdateFramebufferSize(struct gl_context *ctx, const __DRIdrawable *dPriv);
|
||||
|
||||
|
||||
#endif /* DRIRENDERBUFFER_H */
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
#endif
|
||||
|
||||
|
||||
static void TAG(WriteRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -85,7 +85,7 @@ static void TAG(WriteRGBASpan)( GLcontext *ctx,
|
||||
HW_WRITE_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(WriteRGBSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -124,7 +124,7 @@ static void TAG(WriteRGBSpan)( GLcontext *ctx,
|
||||
HW_WRITE_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(WriteRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -170,7 +170,7 @@ static void TAG(WriteRGBAPixels)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(WriteMonoRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value,
|
||||
@@ -210,7 +210,7 @@ static void TAG(WriteMonoRGBASpan)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(WriteMonoRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
@@ -252,7 +252,7 @@ static void TAG(WriteMonoRGBAPixels)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(ReadRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(ReadRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
void *values)
|
||||
@@ -280,7 +280,7 @@ static void TAG(ReadRGBASpan)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(ReadRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(ReadRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
void *values )
|
||||
|
||||
@@ -460,7 +460,7 @@
|
||||
#include "x86/common_x86_asm.h"
|
||||
#endif
|
||||
|
||||
static void TAG(WriteRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -503,7 +503,7 @@ static void TAG(WriteRGBASpan)( GLcontext *ctx,
|
||||
HW_WRITE_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(WriteRGBSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -542,7 +542,7 @@ static void TAG(WriteRGBSpan)( GLcontext *ctx,
|
||||
HW_WRITE_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(WriteRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -588,7 +588,7 @@ static void TAG(WriteRGBAPixels)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(WriteMonoRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value, const GLubyte mask[] )
|
||||
@@ -627,7 +627,7 @@ static void TAG(WriteMonoRGBASpan)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(WriteMonoRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
@@ -669,7 +669,7 @@ static void TAG(WriteMonoRGBAPixels)( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void TAG(ReadRGBASpan)( GLcontext *ctx,
|
||||
static void TAG(ReadRGBASpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y, void *values)
|
||||
{
|
||||
@@ -702,7 +702,7 @@ static void TAG(ReadRGBASpan)( GLcontext *ctx,
|
||||
(SPANTMP_PIXEL_TYPE == GL_UNSIGNED_INT_8_8_8_8_REV)) || \
|
||||
((SPANTMP_PIXEL_FMT == GL_RGB) && \
|
||||
(SPANTMP_PIXEL_TYPE == GL_UNSIGNED_SHORT_5_6_5)))
|
||||
static void TAG2(ReadRGBASpan,_MMX)( GLcontext *ctx,
|
||||
static void TAG2(ReadRGBASpan,_MMX)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y, void *values)
|
||||
{
|
||||
@@ -752,7 +752,7 @@ static void TAG2(ReadRGBASpan,_MMX)( GLcontext *ctx,
|
||||
defined(USE_SSE_ASM) && \
|
||||
(SPANTMP_PIXEL_FMT == GL_BGRA) && \
|
||||
(SPANTMP_PIXEL_TYPE == GL_UNSIGNED_INT_8_8_8_8_REV)
|
||||
static void TAG2(ReadRGBASpan,_SSE2)( GLcontext *ctx,
|
||||
static void TAG2(ReadRGBASpan,_SSE2)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
void *values)
|
||||
@@ -787,7 +787,7 @@ static void TAG2(ReadRGBASpan,_SSE2)( GLcontext *ctx,
|
||||
defined(USE_SSE_ASM) && \
|
||||
(SPANTMP_PIXEL_FMT == GL_BGRA) && \
|
||||
(SPANTMP_PIXEL_TYPE == GL_UNSIGNED_INT_8_8_8_8_REV)
|
||||
static void TAG2(ReadRGBASpan,_SSE)( GLcontext *ctx,
|
||||
static void TAG2(ReadRGBASpan,_SSE)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
void *values)
|
||||
@@ -829,7 +829,7 @@ static void TAG2(ReadRGBASpan,_SSE)( GLcontext *ctx,
|
||||
#endif
|
||||
|
||||
|
||||
static void TAG(ReadRGBAPixels)( GLcontext *ctx,
|
||||
static void TAG(ReadRGBAPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
void *values )
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
#define HAVE_HW_STENCIL_PIXELS 0
|
||||
#endif
|
||||
|
||||
static void TAG(WriteStencilSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteStencilSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *values, const GLubyte mask[] )
|
||||
@@ -64,7 +64,7 @@ static void TAG(WriteStencilSpan)( GLcontext *ctx,
|
||||
#if HAVE_HW_STENCIL_SPANS
|
||||
/* implement MonoWriteDepthSpan() in terms of WriteDepthSpan() */
|
||||
static void
|
||||
TAG(WriteMonoStencilSpan)( GLcontext *ctx, struct gl_renderbuffer *rb,
|
||||
TAG(WriteMonoStencilSpan)( struct gl_context *ctx, struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value, const GLubyte mask[] )
|
||||
{
|
||||
@@ -76,7 +76,7 @@ TAG(WriteMonoStencilSpan)( GLcontext *ctx, struct gl_renderbuffer *rb,
|
||||
TAG(WriteStencilSpan)(ctx, rb, n, x, y, stens, mask);
|
||||
}
|
||||
#else /* HAVE_HW_STENCIL_SPANS */
|
||||
static void TAG(WriteMonoStencilSpan)( GLcontext *ctx,
|
||||
static void TAG(WriteMonoStencilSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
const void *value,
|
||||
@@ -118,7 +118,7 @@ static void TAG(WriteMonoStencilSpan)( GLcontext *ctx,
|
||||
#endif /* !HAVE_HW_STENCIL_SPANS */
|
||||
|
||||
|
||||
static void TAG(WriteStencilPixels)( GLcontext *ctx,
|
||||
static void TAG(WriteStencilPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n,
|
||||
const GLint x[], const GLint y[],
|
||||
@@ -157,7 +157,7 @@ static void TAG(WriteStencilPixels)( GLcontext *ctx,
|
||||
|
||||
/* Read stencil spans and pixels
|
||||
*/
|
||||
static void TAG(ReadStencilSpan)( GLcontext *ctx,
|
||||
static void TAG(ReadStencilSpan)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, GLint x, GLint y,
|
||||
void *values)
|
||||
@@ -190,7 +190,7 @@ static void TAG(ReadStencilSpan)( GLcontext *ctx,
|
||||
HW_READ_UNLOCK();
|
||||
}
|
||||
|
||||
static void TAG(ReadStencilPixels)( GLcontext *ctx,
|
||||
static void TAG(ReadStencilPixels)( struct gl_context *ctx,
|
||||
struct gl_renderbuffer *rb,
|
||||
GLuint n, const GLint x[], const GLint y[],
|
||||
void *values )
|
||||
|
||||
@@ -89,7 +89,7 @@ driLog2( GLuint n )
|
||||
*/
|
||||
|
||||
GLboolean
|
||||
driIsTextureResident( GLcontext * ctx,
|
||||
driIsTextureResident( struct gl_context * ctx,
|
||||
struct gl_texture_object * texObj )
|
||||
{
|
||||
driTextureObject * t;
|
||||
@@ -1047,7 +1047,7 @@ driCalculateMaxTextureLevels( driTexHeap * const * heaps,
|
||||
* \param targets Bit-mask of value texture targets
|
||||
*/
|
||||
|
||||
void driInitTextureObjects( GLcontext *ctx, driTextureObject * swapped,
|
||||
void driInitTextureObjects( struct gl_context *ctx, driTextureObject * swapped,
|
||||
GLuint targets )
|
||||
{
|
||||
struct gl_texture_object *texObj;
|
||||
|
||||
@@ -277,7 +277,7 @@ void driDestroyTextureObject( driTextureObject * t );
|
||||
int driAllocateTexture( driTexHeap * const * heap_array, unsigned nr_heaps,
|
||||
driTextureObject * t );
|
||||
|
||||
GLboolean driIsTextureResident( GLcontext * ctx,
|
||||
GLboolean driIsTextureResident( struct gl_context * ctx,
|
||||
struct gl_texture_object * texObj );
|
||||
|
||||
driTexHeap * driCreateTextureHeap( unsigned heap_id, void * context,
|
||||
@@ -309,7 +309,7 @@ driSetTextureSwapCounterLocation( driTexHeap * heap, unsigned * counter );
|
||||
#define DRI_TEXMGR_DO_TEXTURE_CUBE 0x0008
|
||||
#define DRI_TEXMGR_DO_TEXTURE_RECT 0x0010
|
||||
|
||||
void driInitTextureObjects( GLcontext *ctx, driTextureObject * swapped,
|
||||
void driInitTextureObjects( struct gl_context *ctx, driTextureObject * swapped,
|
||||
GLuint targets );
|
||||
|
||||
GLboolean driValidateTextureHeaps( driTexHeap * const * texture_heaps,
|
||||
|
||||
@@ -198,7 +198,7 @@ static const struct dri_extension all_mesa_extensions[] = {
|
||||
* we need to add entry-points (via \c driInitSingleExtension) for those
|
||||
* new functions here.
|
||||
*/
|
||||
void driInitExtensions( GLcontext * ctx,
|
||||
void driInitExtensions( struct gl_context * ctx,
|
||||
const struct dri_extension * extensions_to_enable,
|
||||
GLboolean enable_imaging )
|
||||
{
|
||||
@@ -239,7 +239,7 @@ void driInitExtensions( GLcontext * ctx,
|
||||
*
|
||||
* \sa driInitExtensions, _mesa_enable_extension, _mesa_map_function_array
|
||||
*/
|
||||
void driInitSingleExtension( GLcontext * ctx,
|
||||
void driInitSingleExtension( struct gl_context * ctx,
|
||||
const struct dri_extension * ext )
|
||||
{
|
||||
if ( ext->functions != NULL ) {
|
||||
|
||||
@@ -78,10 +78,10 @@ extern unsigned driParseDebugString( const char * debug,
|
||||
extern unsigned driGetRendererString( char * buffer,
|
||||
const char * hardware_name, const char * driver_date, GLuint agp_mode );
|
||||
|
||||
extern void driInitExtensions( GLcontext * ctx,
|
||||
extern void driInitExtensions( struct gl_context * ctx,
|
||||
const struct dri_extension * card_extensions, GLboolean enable_imaging );
|
||||
|
||||
extern void driInitSingleExtension( GLcontext * ctx,
|
||||
extern void driInitSingleExtension( struct gl_context * ctx,
|
||||
const struct dri_extension * ext );
|
||||
|
||||
extern GLboolean driCheckDriDdxDrmVersions2(const char * driver_name,
|
||||
|
||||
@@ -69,7 +69,7 @@ const GLuint __driNConfigOptions = 0;
|
||||
|
||||
#define DRIVER_DATE "20050821"
|
||||
|
||||
static const GLubyte *i810GetString( GLcontext *ctx, GLenum name )
|
||||
static const GLubyte *i810GetString( struct gl_context *ctx, GLenum name )
|
||||
{
|
||||
static char buffer[128];
|
||||
|
||||
@@ -170,7 +170,7 @@ i810CreateContext( gl_api api,
|
||||
__DRIcontext *driContextPriv,
|
||||
void *sharedContextPrivate )
|
||||
{
|
||||
GLcontext *ctx, *shareCtx;
|
||||
struct gl_context *ctx, *shareCtx;
|
||||
i810ContextPtr imesa;
|
||||
__DRIscreen *sPriv = driContextPriv->driScreenPriv;
|
||||
i810ScreenPrivate *i810Screen = (i810ScreenPrivate *)sPriv->private;
|
||||
@@ -268,7 +268,7 @@ i810CreateContext( gl_api api,
|
||||
ctx->Const.PointSizeGranularity = 1.0;
|
||||
|
||||
/* reinitialize the context point state.
|
||||
* It depend on constants in __GLcontextRec::Const
|
||||
* It depend on constants in __struct gl_contextRec::Const
|
||||
*/
|
||||
_mesa_init_point(ctx);
|
||||
|
||||
@@ -470,7 +470,7 @@ i810MakeCurrent(__DRIcontext *driContextPriv,
|
||||
static void
|
||||
i810UpdatePageFlipping( i810ContextPtr imesa )
|
||||
{
|
||||
GLcontext *ctx = imesa->glCtx;
|
||||
struct gl_context *ctx = imesa->glCtx;
|
||||
int front = 0;
|
||||
|
||||
/* Determine current color drawing buffer */
|
||||
@@ -552,7 +552,7 @@ i810SwapBuffers( __DRIdrawable *dPriv )
|
||||
{
|
||||
if (dPriv->driContextPriv && dPriv->driContextPriv->driverPrivate) {
|
||||
i810ContextPtr imesa;
|
||||
GLcontext *ctx;
|
||||
struct gl_context *ctx;
|
||||
imesa = (i810ContextPtr) dPriv->driContextPriv->driverPrivate;
|
||||
ctx = imesa->glCtx;
|
||||
if (ctx->Visual.doubleBufferMode) {
|
||||
|
||||
@@ -79,7 +79,7 @@ typedef void (*i810_point_func)( i810ContextPtr, i810Vertex * );
|
||||
|
||||
struct i810_context_t {
|
||||
GLint refcount;
|
||||
GLcontext *glCtx;
|
||||
struct gl_context *glCtx;
|
||||
|
||||
/* Texture object bookkeeping
|
||||
*/
|
||||
|
||||
@@ -47,7 +47,7 @@ static drmBufPtr i810_get_buffer_ioctl( i810ContextPtr imesa )
|
||||
|
||||
#define DEPTH_SCALE ((1<<16)-1)
|
||||
|
||||
static void i810Clear( GLcontext *ctx, GLbitfield mask )
|
||||
static void i810Clear( struct gl_context *ctx, GLbitfield mask )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
__DRIdrawable *dPriv = imesa->driDrawable;
|
||||
@@ -499,13 +499,13 @@ int i810_check_copy(int fd)
|
||||
return(drmCommandNone(fd, DRM_I810_DOCOPY));
|
||||
}
|
||||
|
||||
static void i810Flush( GLcontext *ctx )
|
||||
static void i810Flush( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
I810_FIREVERTICES( imesa );
|
||||
}
|
||||
|
||||
static void i810Finish( GLcontext *ctx )
|
||||
static void i810Finish( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
i810DmaFinish( imesa );
|
||||
|
||||
@@ -124,7 +124,7 @@ static const GLenum reduced_prim[GL_POLYGON+1] = {
|
||||
/**********************************************************************/
|
||||
|
||||
|
||||
static GLboolean i810_run_render( GLcontext *ctx,
|
||||
static GLboolean i810_run_render( struct gl_context *ctx,
|
||||
struct tnl_pipeline_stage *stage )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
|
||||
@@ -81,7 +81,7 @@ do { \
|
||||
|
||||
/* Move locking out to get reasonable span performance.
|
||||
*/
|
||||
void i810SpanRenderStart( GLcontext *ctx )
|
||||
void i810SpanRenderStart( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
I810_FIREVERTICES(imesa);
|
||||
@@ -89,14 +89,14 @@ void i810SpanRenderStart( GLcontext *ctx )
|
||||
i810RegetLockQuiescent( imesa );
|
||||
}
|
||||
|
||||
void i810SpanRenderFinish( GLcontext *ctx )
|
||||
void i810SpanRenderFinish( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
_swrast_flush( ctx );
|
||||
UNLOCK_HARDWARE( imesa );
|
||||
}
|
||||
|
||||
void i810InitSpanFuncs( GLcontext *ctx )
|
||||
void i810InitSpanFuncs( struct gl_context *ctx )
|
||||
{
|
||||
struct swrast_device_driver *swdd = _swrast_GetDeviceDriverReference(ctx);
|
||||
swdd->SpanRenderStart = i810SpanRenderStart;
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
|
||||
#include "drirenderbuffer.h"
|
||||
|
||||
extern void i810InitSpanFuncs( GLcontext *ctx );
|
||||
extern void i810InitSpanFuncs( struct gl_context *ctx );
|
||||
|
||||
extern void i810SpanRenderFinish( GLcontext *ctx );
|
||||
extern void i810SpanRenderStart( GLcontext *ctx );
|
||||
extern void i810SpanRenderFinish( struct gl_context *ctx );
|
||||
extern void i810SpanRenderStart( struct gl_context *ctx );
|
||||
|
||||
extern void
|
||||
i810SetSpanFunctions(driRenderbuffer *rb, const struct gl_config *vis);
|
||||
|
||||
@@ -43,7 +43,7 @@ static INLINE GLuint i810PackColor(GLuint format,
|
||||
}
|
||||
|
||||
|
||||
static void i810AlphaFunc(GLcontext *ctx, GLenum func, GLfloat ref)
|
||||
static void i810AlphaFunc(struct gl_context *ctx, GLenum func, GLfloat ref)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
GLuint a = (ZA_UPDATE_ALPHAFUNC|ZA_UPDATE_ALPHAREF);
|
||||
@@ -70,7 +70,7 @@ static void i810AlphaFunc(GLcontext *ctx, GLenum func, GLfloat ref)
|
||||
imesa->Setup[I810_CTXREG_ZA] |= a;
|
||||
}
|
||||
|
||||
static void i810BlendEquationSeparate(GLcontext *ctx,
|
||||
static void i810BlendEquationSeparate(struct gl_context *ctx,
|
||||
GLenum modeRGB, GLenum modeA)
|
||||
{
|
||||
assert( modeRGB == modeA );
|
||||
@@ -87,7 +87,7 @@ static void i810BlendEquationSeparate(GLcontext *ctx,
|
||||
ctx->Color.LogicOp != GL_COPY));
|
||||
}
|
||||
|
||||
static void i810BlendFuncSeparate( GLcontext *ctx, GLenum sfactorRGB,
|
||||
static void i810BlendFuncSeparate( struct gl_context *ctx, GLenum sfactorRGB,
|
||||
GLenum dfactorRGB, GLenum sfactorA,
|
||||
GLenum dfactorA )
|
||||
{
|
||||
@@ -156,7 +156,7 @@ static void i810BlendFuncSeparate( GLcontext *ctx, GLenum sfactorRGB,
|
||||
|
||||
|
||||
|
||||
static void i810DepthFunc(GLcontext *ctx, GLenum func)
|
||||
static void i810DepthFunc(struct gl_context *ctx, GLenum func)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
int zmode;
|
||||
@@ -178,7 +178,7 @@ static void i810DepthFunc(GLcontext *ctx, GLenum func)
|
||||
imesa->Setup[I810_CTXREG_LCS] |= zmode;
|
||||
}
|
||||
|
||||
static void i810DepthMask(GLcontext *ctx, GLboolean flag)
|
||||
static void i810DepthMask(struct gl_context *ctx, GLboolean flag)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
I810_STATECHANGE(imesa, I810_UPLOAD_CTX);
|
||||
@@ -196,7 +196,7 @@ static void i810DepthMask(GLcontext *ctx, GLboolean flag)
|
||||
* The i810 supports a 4x4 stipple natively, GL wants 32x32.
|
||||
* Fortunately stipple is usually a repeating pattern.
|
||||
*/
|
||||
static void i810PolygonStipple( GLcontext *ctx, const GLubyte *mask )
|
||||
static void i810PolygonStipple( struct gl_context *ctx, const GLubyte *mask )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
const GLubyte *m = mask;
|
||||
@@ -250,7 +250,7 @@ static void i810PolygonStipple( GLcontext *ctx, const GLubyte *mask )
|
||||
*/
|
||||
|
||||
|
||||
static void i810Scissor( GLcontext *ctx, GLint x, GLint y,
|
||||
static void i810Scissor( struct gl_context *ctx, GLint x, GLint y,
|
||||
GLsizei w, GLsizei h )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -267,7 +267,7 @@ static void i810Scissor( GLcontext *ctx, GLint x, GLint y,
|
||||
}
|
||||
|
||||
|
||||
static void i810LogicOp( GLcontext *ctx, GLenum opcode )
|
||||
static void i810LogicOp( struct gl_context *ctx, GLenum opcode )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
FALLBACK( imesa, I810_FALLBACK_LOGICOP,
|
||||
@@ -276,14 +276,14 @@ static void i810LogicOp( GLcontext *ctx, GLenum opcode )
|
||||
|
||||
/* Fallback to swrast for select and feedback.
|
||||
*/
|
||||
static void i810RenderMode( GLcontext *ctx, GLenum mode )
|
||||
static void i810RenderMode( struct gl_context *ctx, GLenum mode )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
FALLBACK( imesa, I810_FALLBACK_RENDERMODE, (mode != GL_RENDER) );
|
||||
}
|
||||
|
||||
|
||||
void i810DrawBuffer(GLcontext *ctx, GLenum mode )
|
||||
void i810DrawBuffer(struct gl_context *ctx, GLenum mode )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
int front = 0;
|
||||
@@ -328,13 +328,13 @@ void i810DrawBuffer(GLcontext *ctx, GLenum mode )
|
||||
}
|
||||
|
||||
|
||||
static void i810ReadBuffer(GLcontext *ctx, GLenum mode )
|
||||
static void i810ReadBuffer(struct gl_context *ctx, GLenum mode )
|
||||
{
|
||||
/* XXX anything? */
|
||||
}
|
||||
|
||||
|
||||
static void i810ClearColor(GLcontext *ctx, const GLfloat color[4] )
|
||||
static void i810ClearColor(struct gl_context *ctx, const GLfloat color[4] )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
GLubyte c[4];
|
||||
@@ -351,7 +351,7 @@ static void i810ClearColor(GLcontext *ctx, const GLfloat color[4] )
|
||||
* Culling - the i810 isn't quite as clean here as the rest of
|
||||
* its interfaces, but it's not bad.
|
||||
*/
|
||||
static void i810CullFaceFrontFace(GLcontext *ctx, GLenum unused)
|
||||
static void i810CullFaceFrontFace(struct gl_context *ctx, GLenum unused)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
GLuint mode = LCS_CULL_BOTH;
|
||||
@@ -375,7 +375,7 @@ static void i810CullFaceFrontFace(GLcontext *ctx, GLenum unused)
|
||||
}
|
||||
|
||||
|
||||
static void i810LineWidth( GLcontext *ctx, GLfloat widthf )
|
||||
static void i810LineWidth( struct gl_context *ctx, GLfloat widthf )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
/* AA, non-AA limits are same */
|
||||
@@ -394,7 +394,7 @@ static void i810LineWidth( GLcontext *ctx, GLfloat widthf )
|
||||
}
|
||||
}
|
||||
|
||||
static void i810PointSize( GLcontext *ctx, GLfloat sz )
|
||||
static void i810PointSize( struct gl_context *ctx, GLfloat sz )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
/* AA, non-AA limits are same */
|
||||
@@ -417,7 +417,7 @@ static void i810PointSize( GLcontext *ctx, GLfloat sz )
|
||||
* Color masks
|
||||
*/
|
||||
|
||||
static void i810ColorMask(GLcontext *ctx,
|
||||
static void i810ColorMask(struct gl_context *ctx,
|
||||
GLboolean r, GLboolean g,
|
||||
GLboolean b, GLboolean a )
|
||||
{
|
||||
@@ -444,7 +444,7 @@ static void i810ColorMask(GLcontext *ctx,
|
||||
|
||||
/* Seperate specular not fully implemented on the i810.
|
||||
*/
|
||||
static void i810LightModelfv(GLcontext *ctx, GLenum pname,
|
||||
static void i810LightModelfv(struct gl_context *ctx, GLenum pname,
|
||||
const GLfloat *param)
|
||||
{
|
||||
if (pname == GL_LIGHT_MODEL_COLOR_CONTROL)
|
||||
@@ -458,7 +458,7 @@ static void i810LightModelfv(GLcontext *ctx, GLenum pname,
|
||||
|
||||
/* But the 815 has it...
|
||||
*/
|
||||
static void i810LightModelfv_i815(GLcontext *ctx, GLenum pname,
|
||||
static void i810LightModelfv_i815(struct gl_context *ctx, GLenum pname,
|
||||
const GLfloat *param)
|
||||
{
|
||||
if (pname == GL_LIGHT_MODEL_COLOR_CONTROL)
|
||||
@@ -475,7 +475,7 @@ static void i810LightModelfv_i815(GLcontext *ctx, GLenum pname,
|
||||
|
||||
/* In Mesa 3.5 we can reliably do native flatshading.
|
||||
*/
|
||||
static void i810ShadeModel(GLcontext *ctx, GLenum mode)
|
||||
static void i810ShadeModel(struct gl_context *ctx, GLenum mode)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
I810_STATECHANGE(imesa, I810_UPLOAD_CTX);
|
||||
@@ -490,7 +490,7 @@ static void i810ShadeModel(GLcontext *ctx, GLenum mode)
|
||||
/* =============================================================
|
||||
* Fog
|
||||
*/
|
||||
static void i810Fogfv(GLcontext *ctx, GLenum pname, const GLfloat *param)
|
||||
static void i810Fogfv(struct gl_context *ctx, GLenum pname, const GLfloat *param)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
|
||||
@@ -508,7 +508,7 @@ static void i810Fogfv(GLcontext *ctx, GLenum pname, const GLfloat *param)
|
||||
|
||||
/* =============================================================
|
||||
*/
|
||||
static void i810Enable(GLcontext *ctx, GLenum cap, GLboolean state)
|
||||
static void i810Enable(struct gl_context *ctx, GLenum cap, GLboolean state)
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
|
||||
@@ -672,7 +672,7 @@ void i810EmitDrawingRectangle( i810ContextPtr imesa )
|
||||
|
||||
|
||||
|
||||
static void i810CalcViewport( GLcontext *ctx )
|
||||
static void i810CalcViewport( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
const GLfloat *v = ctx->Viewport._WindowMap.m;
|
||||
@@ -689,14 +689,14 @@ static void i810CalcViewport( GLcontext *ctx )
|
||||
m[MAT_TZ] = v[MAT_TZ] * (1.0 / 0xffff);
|
||||
}
|
||||
|
||||
static void i810Viewport( GLcontext *ctx,
|
||||
static void i810Viewport( struct gl_context *ctx,
|
||||
GLint x, GLint y,
|
||||
GLsizei width, GLsizei height )
|
||||
{
|
||||
i810CalcViewport( ctx );
|
||||
}
|
||||
|
||||
static void i810DepthRange( GLcontext *ctx,
|
||||
static void i810DepthRange( struct gl_context *ctx,
|
||||
GLclampd nearval, GLclampd farval )
|
||||
{
|
||||
i810CalcViewport( ctx );
|
||||
@@ -718,7 +718,7 @@ void i810PrintDirty( const char *msg, GLuint state )
|
||||
|
||||
|
||||
|
||||
void i810InitState( GLcontext *ctx )
|
||||
void i810InitState( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
i810ScreenPrivate *i810Screen = imesa->i810Screen;
|
||||
@@ -953,7 +953,7 @@ void i810InitState( GLcontext *ctx )
|
||||
}
|
||||
|
||||
|
||||
static void i810InvalidateState( GLcontext *ctx, GLuint new_state )
|
||||
static void i810InvalidateState( struct gl_context *ctx, GLuint new_state )
|
||||
{
|
||||
_swrast_InvalidateState( ctx, new_state );
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
@@ -963,7 +963,7 @@ static void i810InvalidateState( GLcontext *ctx, GLuint new_state )
|
||||
}
|
||||
|
||||
|
||||
void i810InitStateFuncs(GLcontext *ctx)
|
||||
void i810InitStateFuncs(struct gl_context *ctx)
|
||||
{
|
||||
/* Callbacks for internal Mesa events.
|
||||
*/
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
|
||||
#include "i810context.h"
|
||||
|
||||
extern void i810InitState( GLcontext *ctx );
|
||||
extern void i810InitStateFuncs( GLcontext *ctx );
|
||||
extern void i810InitState( struct gl_context *ctx );
|
||||
extern void i810InitStateFuncs( struct gl_context *ctx );
|
||||
extern void i810PrintDirty( const char *msg, GLuint state );
|
||||
extern void i810DrawBuffer(GLcontext *ctx, GLenum mode );
|
||||
extern void i810DrawBuffer(struct gl_context *ctx, GLenum mode );
|
||||
|
||||
extern void i810Fallback( i810ContextPtr imesa, GLuint bit, GLboolean mode );
|
||||
#define FALLBACK( imesa, bit, mode ) i810Fallback( imesa, bit, mode )
|
||||
|
||||
@@ -166,7 +166,7 @@ i810SetTexBorderColor( i810TextureObjectPtr t, const GLfloat color[4] )
|
||||
|
||||
|
||||
static i810TextureObjectPtr
|
||||
i810AllocTexObj( GLcontext *ctx, struct gl_texture_object *texObj )
|
||||
i810AllocTexObj( struct gl_context *ctx, struct gl_texture_object *texObj )
|
||||
{
|
||||
i810TextureObjectPtr t;
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -214,7 +214,7 @@ i810AllocTexObj( GLcontext *ctx, struct gl_texture_object *texObj )
|
||||
}
|
||||
|
||||
|
||||
static void i810TexParameter( GLcontext *ctx, GLenum target,
|
||||
static void i810TexParameter( struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *tObj,
|
||||
GLenum pname, const GLfloat *params )
|
||||
{
|
||||
@@ -285,7 +285,7 @@ static void i810TexParameter( GLcontext *ctx, GLenum target,
|
||||
* Determine whether or not \c param can be used instead of
|
||||
* \c texUnit->EnvColor in the \c GL_TEXTURE_ENV_COLOR case.
|
||||
*/
|
||||
static void i810TexEnv( GLcontext *ctx, GLenum target,
|
||||
static void i810TexEnv( struct gl_context *ctx, GLenum target,
|
||||
GLenum pname, const GLfloat *param )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
@@ -333,7 +333,7 @@ static void i810TexEnv( GLcontext *ctx, GLenum target,
|
||||
|
||||
|
||||
#if 0
|
||||
static void i810TexImage1D( GLcontext *ctx, GLenum target, GLint level,
|
||||
static void i810TexImage1D( struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint internalFormat,
|
||||
GLint width, GLint border,
|
||||
GLenum format, GLenum type,
|
||||
@@ -348,7 +348,7 @@ static void i810TexImage1D( GLcontext *ctx, GLenum target, GLint level,
|
||||
}
|
||||
}
|
||||
|
||||
static void i810TexSubImage1D( GLcontext *ctx,
|
||||
static void i810TexSubImage1D( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
GLint level,
|
||||
GLint xoffset,
|
||||
@@ -363,7 +363,7 @@ static void i810TexSubImage1D( GLcontext *ctx,
|
||||
#endif
|
||||
|
||||
|
||||
static void i810TexImage2D( GLcontext *ctx, GLenum target, GLint level,
|
||||
static void i810TexImage2D( struct gl_context *ctx, GLenum target, GLint level,
|
||||
GLint internalFormat,
|
||||
GLint width, GLint height, GLint border,
|
||||
GLenum format, GLenum type, const GLvoid *pixels,
|
||||
@@ -388,7 +388,7 @@ static void i810TexImage2D( GLcontext *ctx, GLenum target, GLint level,
|
||||
pixels, packing, texObj, texImage );
|
||||
}
|
||||
|
||||
static void i810TexSubImage2D( GLcontext *ctx,
|
||||
static void i810TexSubImage2D( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
GLint level,
|
||||
GLint xoffset, GLint yoffset,
|
||||
@@ -410,14 +410,14 @@ static void i810TexSubImage2D( GLcontext *ctx,
|
||||
}
|
||||
|
||||
|
||||
static void i810BindTexture( GLcontext *ctx, GLenum target,
|
||||
static void i810BindTexture( struct gl_context *ctx, GLenum target,
|
||||
struct gl_texture_object *tObj )
|
||||
{
|
||||
assert( (target != GL_TEXTURE_2D) || (tObj->DriverData != NULL) );
|
||||
}
|
||||
|
||||
|
||||
static void i810DeleteTexture( GLcontext *ctx, struct gl_texture_object *tObj )
|
||||
static void i810DeleteTexture( struct gl_context *ctx, struct gl_texture_object *tObj )
|
||||
{
|
||||
driTextureObject * t = (driTextureObject *) tObj->DriverData;
|
||||
if (t) {
|
||||
@@ -437,7 +437,7 @@ static void i810DeleteTexture( GLcontext *ctx, struct gl_texture_object *tObj )
|
||||
* makes this routine pretty simple.
|
||||
*/
|
||||
static gl_format
|
||||
i810ChooseTextureFormat( GLcontext *ctx, GLint internalFormat,
|
||||
i810ChooseTextureFormat( struct gl_context *ctx, GLint internalFormat,
|
||||
GLenum format, GLenum type )
|
||||
{
|
||||
switch ( internalFormat ) {
|
||||
@@ -524,7 +524,7 @@ i810ChooseTextureFormat( GLcontext *ctx, GLint internalFormat,
|
||||
* texture object from the core mesa gl_texture_object. Not done at this time.
|
||||
*/
|
||||
static struct gl_texture_object *
|
||||
i810NewTextureObject( GLcontext *ctx, GLuint name, GLenum target )
|
||||
i810NewTextureObject( struct gl_context *ctx, GLuint name, GLenum target )
|
||||
{
|
||||
struct gl_texture_object *obj;
|
||||
obj = _mesa_new_texture_object(ctx, name, target);
|
||||
|
||||
@@ -68,7 +68,7 @@ struct i810_texture_object_t {
|
||||
|
||||
};
|
||||
|
||||
void i810UpdateTextureState( GLcontext *ctx );
|
||||
void i810UpdateTextureState( struct gl_context *ctx );
|
||||
void i810InitTextureFuncs( struct dd_function_table *functions );
|
||||
|
||||
void i810DestroyTexObj( i810ContextPtr imesa, i810TextureObjectPtr t );
|
||||
|
||||
@@ -191,7 +191,7 @@ static const unsigned operand_modifiers[] = {
|
||||
* a reasonable place to make note of it.
|
||||
*/
|
||||
static GLboolean
|
||||
i810UpdateTexEnvCombine( GLcontext *ctx, GLuint unit,
|
||||
i810UpdateTexEnvCombine( struct gl_context *ctx, GLuint unit,
|
||||
int * color_stage, int * alpha_stage )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -533,7 +533,7 @@ i810UpdateTexEnvCombine( GLcontext *ctx, GLuint unit,
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
static GLboolean enable_tex_common( GLcontext *ctx, GLuint unit )
|
||||
static GLboolean enable_tex_common( struct gl_context *ctx, GLuint unit )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit];
|
||||
@@ -570,7 +570,7 @@ static GLboolean enable_tex_common( GLcontext *ctx, GLuint unit )
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
static GLboolean enable_tex_rect( GLcontext *ctx, GLuint unit )
|
||||
static GLboolean enable_tex_rect( struct gl_context *ctx, GLuint unit )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit];
|
||||
@@ -590,7 +590,7 @@ static GLboolean enable_tex_rect( GLcontext *ctx, GLuint unit )
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
static GLboolean enable_tex_2d( GLcontext *ctx, GLuint unit )
|
||||
static GLboolean enable_tex_2d( struct gl_context *ctx, GLuint unit )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit];
|
||||
@@ -610,7 +610,7 @@ static GLboolean enable_tex_2d( GLcontext *ctx, GLuint unit )
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
static void disable_tex( GLcontext *ctx, GLuint unit )
|
||||
static void disable_tex( struct gl_context *ctx, GLuint unit )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
|
||||
@@ -627,7 +627,7 @@ static void disable_tex( GLcontext *ctx, GLuint unit )
|
||||
* 1D textures should be supported! Just use a 2D texture with the second
|
||||
* texture coordinate value fixed at 0.0.
|
||||
*/
|
||||
static void i810UpdateTexUnit( GLcontext *ctx, GLuint unit,
|
||||
static void i810UpdateTexUnit( struct gl_context *ctx, GLuint unit,
|
||||
int * next_color_stage, int * next_alpha_stage )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -664,7 +664,7 @@ static void i810UpdateTexUnit( GLcontext *ctx, GLuint unit,
|
||||
}
|
||||
|
||||
|
||||
void i810UpdateTextureState( GLcontext *ctx )
|
||||
void i810UpdateTextureState( struct gl_context *ctx )
|
||||
{
|
||||
static const unsigned color_pass[3] = {
|
||||
GFX_OP_MAP_COLOR_STAGES | MC_STAGE_0 | MC_UPDATE_DEST | MC_DEST_CURRENT
|
||||
|
||||
@@ -49,7 +49,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
#include "i810vb.h"
|
||||
#include "i810ioctl.h"
|
||||
|
||||
static void i810RenderPrimitive( GLcontext *ctx, GLenum prim );
|
||||
static void i810RenderPrimitive( struct gl_context *ctx, GLenum prim );
|
||||
|
||||
/***********************************************************************
|
||||
* Emit primitives as inline vertices *
|
||||
@@ -407,7 +407,7 @@ i810_fallback_tri( i810ContextPtr imesa,
|
||||
i810Vertex *v1,
|
||||
i810Vertex *v2 )
|
||||
{
|
||||
GLcontext *ctx = imesa->glCtx;
|
||||
struct gl_context *ctx = imesa->glCtx;
|
||||
SWvertex v[3];
|
||||
i810_translate_vertex( ctx, v0, &v[0] );
|
||||
i810_translate_vertex( ctx, v1, &v[1] );
|
||||
@@ -421,7 +421,7 @@ i810_fallback_line( i810ContextPtr imesa,
|
||||
i810Vertex *v0,
|
||||
i810Vertex *v1 )
|
||||
{
|
||||
GLcontext *ctx = imesa->glCtx;
|
||||
struct gl_context *ctx = imesa->glCtx;
|
||||
SWvertex v[2];
|
||||
i810_translate_vertex( ctx, v0, &v[0] );
|
||||
i810_translate_vertex( ctx, v1, &v[1] );
|
||||
@@ -433,7 +433,7 @@ static void
|
||||
i810_fallback_point( i810ContextPtr imesa,
|
||||
i810Vertex *v0 )
|
||||
{
|
||||
GLcontext *ctx = imesa->glCtx;
|
||||
struct gl_context *ctx = imesa->glCtx;
|
||||
SWvertex v[1];
|
||||
i810_translate_vertex( ctx, v0, &v[0] );
|
||||
_swrast_Point( ctx, &v[0] );
|
||||
@@ -478,7 +478,7 @@ i810_fallback_point( i810ContextPtr imesa,
|
||||
|
||||
|
||||
|
||||
static void i810RenderClippedPoly( GLcontext *ctx, const GLuint *elts,
|
||||
static void i810RenderClippedPoly( struct gl_context *ctx, const GLuint *elts,
|
||||
GLuint n )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -502,13 +502,13 @@ static void i810RenderClippedPoly( GLcontext *ctx, const GLuint *elts,
|
||||
tnl->Driver.Render.PrimitiveNotify( ctx, prim );
|
||||
}
|
||||
|
||||
static void i810RenderClippedLine( GLcontext *ctx, GLuint ii, GLuint jj )
|
||||
static void i810RenderClippedLine( struct gl_context *ctx, GLuint ii, GLuint jj )
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
tnl->Driver.Render.Line( ctx, ii, jj );
|
||||
}
|
||||
|
||||
static void i810FastRenderClippedPoly( GLcontext *ctx, const GLuint *elts,
|
||||
static void i810FastRenderClippedPoly( struct gl_context *ctx, const GLuint *elts,
|
||||
GLuint n )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
@@ -549,7 +549,7 @@ static void i810FastRenderClippedPoly( GLcontext *ctx, const GLuint *elts,
|
||||
DD_TRI_STIPPLE)
|
||||
#define ANY_RASTER_FLAGS (DD_TRI_LIGHT_TWOSIDE|DD_TRI_OFFSET|DD_TRI_UNFILLED)
|
||||
|
||||
static void i810ChooseRenderState(GLcontext *ctx)
|
||||
static void i810ChooseRenderState(struct gl_context *ctx)
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
@@ -640,7 +640,7 @@ static const GLenum reduced_prim[GL_POLYGON+1] = {
|
||||
* which renders strips as strips, the equivalent calculations are
|
||||
* performed in i810render.c.
|
||||
*/
|
||||
static void i810RenderPrimitive( GLcontext *ctx, GLenum prim )
|
||||
static void i810RenderPrimitive( struct gl_context *ctx, GLenum prim )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
GLuint rprim = reduced_prim[prim];
|
||||
@@ -656,7 +656,7 @@ static void i810RenderPrimitive( GLcontext *ctx, GLenum prim )
|
||||
}
|
||||
}
|
||||
|
||||
static void i810RunPipeline( GLcontext *ctx )
|
||||
static void i810RunPipeline( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
|
||||
@@ -678,7 +678,7 @@ static void i810RunPipeline( GLcontext *ctx )
|
||||
_tnl_run_pipeline( ctx );
|
||||
}
|
||||
|
||||
static void i810RenderStart( GLcontext *ctx )
|
||||
static void i810RenderStart( struct gl_context *ctx )
|
||||
{
|
||||
/* Check for projective textureing. Make sure all texcoord
|
||||
* pointers point to something. (fix in mesa?)
|
||||
@@ -686,7 +686,7 @@ static void i810RenderStart( GLcontext *ctx )
|
||||
i810CheckTexSizes( ctx );
|
||||
}
|
||||
|
||||
static void i810RenderFinish( GLcontext *ctx )
|
||||
static void i810RenderFinish( struct gl_context *ctx )
|
||||
{
|
||||
if (I810_CONTEXT(ctx)->RenderIndex & I810_FALLBACK_BIT)
|
||||
_swrast_flush( ctx );
|
||||
@@ -698,7 +698,7 @@ static void i810RenderFinish( GLcontext *ctx )
|
||||
/* System to flush dma and emit state changes based on the rasterized
|
||||
* primitive.
|
||||
*/
|
||||
void i810RasterPrimitive( GLcontext *ctx,
|
||||
void i810RasterPrimitive( struct gl_context *ctx,
|
||||
GLenum rprim,
|
||||
GLuint hwprim )
|
||||
{
|
||||
@@ -815,7 +815,7 @@ static char *getFallbackString(GLuint bit)
|
||||
|
||||
void i810Fallback( i810ContextPtr imesa, GLuint bit, GLboolean mode )
|
||||
{
|
||||
GLcontext *ctx = imesa->glCtx;
|
||||
struct gl_context *ctx = imesa->glCtx;
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
GLuint oldfallback = imesa->Fallback;
|
||||
|
||||
@@ -853,7 +853,7 @@ void i810Fallback( i810ContextPtr imesa, GLuint bit, GLboolean mode )
|
||||
/**********************************************************************/
|
||||
|
||||
|
||||
void i810InitTriFuncs( GLcontext *ctx )
|
||||
void i810InitTriFuncs( struct gl_context *ctx )
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
static int firsttime = 1;
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
#include "main/mtypes.h"
|
||||
|
||||
extern void i810PrintRenderState( const char *msg, GLuint state );
|
||||
extern void i810InitTriFuncs( GLcontext *ctx );
|
||||
extern void i810RasterPrimitive( GLcontext *ctx, GLenum rprim, GLuint hwprim );
|
||||
extern void i810InitTriFuncs( struct gl_context *ctx );
|
||||
extern void i810RasterPrimitive( struct gl_context *ctx, GLenum rprim, GLuint hwprim );
|
||||
|
||||
#endif
|
||||
|
||||
@@ -51,10 +51,10 @@
|
||||
#define I810_MAX_SETUP 0x80
|
||||
|
||||
static struct {
|
||||
void (*emit)( GLcontext *, GLuint, GLuint, void *, GLuint );
|
||||
void (*emit)( struct gl_context *, GLuint, GLuint, void *, GLuint );
|
||||
tnl_interp_func interp;
|
||||
tnl_copy_pv_func copy_pv;
|
||||
GLboolean (*check_tex_sizes)( GLcontext *ctx );
|
||||
GLboolean (*check_tex_sizes)( struct gl_context *ctx );
|
||||
GLuint vertex_size;
|
||||
GLuint vertex_format;
|
||||
} setup_tab[I810_MAX_SETUP];
|
||||
@@ -335,7 +335,7 @@ static void i810PrintSetupFlags(const char *msg, GLuint flags )
|
||||
|
||||
|
||||
|
||||
void i810CheckTexSizes( GLcontext *ctx )
|
||||
void i810CheckTexSizes( struct gl_context *ctx )
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
@@ -357,7 +357,7 @@ void i810CheckTexSizes( GLcontext *ctx )
|
||||
}
|
||||
}
|
||||
|
||||
void i810BuildVertices( GLcontext *ctx,
|
||||
void i810BuildVertices( struct gl_context *ctx,
|
||||
GLuint start,
|
||||
GLuint count,
|
||||
GLuint newinputs )
|
||||
@@ -405,7 +405,7 @@ void i810BuildVertices( GLcontext *ctx,
|
||||
}
|
||||
}
|
||||
|
||||
void i810ChooseVertexState( GLcontext *ctx )
|
||||
void i810ChooseVertexState( struct gl_context *ctx )
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
i810ContextPtr imesa = I810_CONTEXT( ctx );
|
||||
@@ -446,7 +446,7 @@ void i810ChooseVertexState( GLcontext *ctx )
|
||||
|
||||
|
||||
|
||||
void *i810_emit_contiguous_verts( GLcontext *ctx,
|
||||
void *i810_emit_contiguous_verts( struct gl_context *ctx,
|
||||
GLuint start,
|
||||
GLuint count,
|
||||
void *dest )
|
||||
@@ -459,7 +459,7 @@ void *i810_emit_contiguous_verts( GLcontext *ctx,
|
||||
|
||||
|
||||
|
||||
void i810InitVB( GLcontext *ctx )
|
||||
void i810InitVB( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
GLuint size = TNL_CONTEXT(ctx)->vb.Size;
|
||||
@@ -476,7 +476,7 @@ void i810InitVB( GLcontext *ctx )
|
||||
}
|
||||
|
||||
|
||||
void i810FreeVB( GLcontext *ctx )
|
||||
void i810FreeVB( struct gl_context *ctx )
|
||||
{
|
||||
i810ContextPtr imesa = I810_CONTEXT(ctx);
|
||||
if (imesa->verts) {
|
||||
|
||||
@@ -36,24 +36,24 @@
|
||||
_NEW_FOG)
|
||||
|
||||
|
||||
extern void i810ChooseVertexState( GLcontext *ctx );
|
||||
extern void i810CheckTexSizes( GLcontext *ctx );
|
||||
extern void i810BuildVertices( GLcontext *ctx,
|
||||
extern void i810ChooseVertexState( struct gl_context *ctx );
|
||||
extern void i810CheckTexSizes( struct gl_context *ctx );
|
||||
extern void i810BuildVertices( struct gl_context *ctx,
|
||||
GLuint start,
|
||||
GLuint count,
|
||||
GLuint newinputs );
|
||||
|
||||
|
||||
extern void *i810_emit_contiguous_verts( GLcontext *ctx,
|
||||
extern void *i810_emit_contiguous_verts( struct gl_context *ctx,
|
||||
GLuint start,
|
||||
GLuint count,
|
||||
void *dest );
|
||||
|
||||
extern void i810_translate_vertex( GLcontext *ctx,
|
||||
extern void i810_translate_vertex( struct gl_context *ctx,
|
||||
const i810Vertex *src,
|
||||
SWvertex *dst );
|
||||
|
||||
extern void i810InitVB( GLcontext *ctx );
|
||||
extern void i810FreeVB( GLcontext *ctx );
|
||||
extern void i810InitVB( struct gl_context *ctx );
|
||||
extern void i810FreeVB( struct gl_context *ctx );
|
||||
|
||||
#endif
|
||||
|
||||
@@ -55,7 +55,7 @@ i830CreateContext(const struct gl_config * mesaVis,
|
||||
struct dd_function_table functions;
|
||||
struct i830_context *i830 = CALLOC_STRUCT(i830_context);
|
||||
struct intel_context *intel = &i830->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
if (!i830)
|
||||
return GL_FALSE;
|
||||
|
||||
|
||||
@@ -205,14 +205,14 @@ extern void i830InitStateFuncs(struct dd_function_table *functions);
|
||||
extern void i830EmitState(struct i830_context *i830);
|
||||
|
||||
extern void i830InitState(struct i830_context *i830);
|
||||
extern void i830_update_provoking_vertex(GLcontext *ctx);
|
||||
extern void i830_update_provoking_vertex(struct gl_context *ctx);
|
||||
|
||||
/*======================================================================
|
||||
* Inline conversion functions. These are better-typed than the
|
||||
* macros used previously:
|
||||
*/
|
||||
static INLINE struct i830_context *
|
||||
i830_context(GLcontext * ctx)
|
||||
i830_context(struct gl_context * ctx)
|
||||
{
|
||||
return (struct i830_context *) ctx;
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
#define FILE_DEBUG_FLAG DEBUG_STATE
|
||||
|
||||
static void
|
||||
i830StencilFuncSeparate(GLcontext * ctx, GLenum face, GLenum func, GLint ref,
|
||||
i830StencilFuncSeparate(struct gl_context * ctx, GLenum face, GLenum func, GLint ref,
|
||||
GLuint mask)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
@@ -72,7 +72,7 @@ i830StencilFuncSeparate(GLcontext * ctx, GLenum face, GLenum func, GLint ref,
|
||||
}
|
||||
|
||||
static void
|
||||
i830StencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask)
|
||||
i830StencilMaskSeparate(struct gl_context * ctx, GLenum face, GLuint mask)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -87,7 +87,7 @@ i830StencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask)
|
||||
}
|
||||
|
||||
static void
|
||||
i830StencilOpSeparate(GLcontext * ctx, GLenum face, GLenum fail, GLenum zfail,
|
||||
i830StencilOpSeparate(struct gl_context * ctx, GLenum face, GLenum fail, GLenum zfail,
|
||||
GLenum zpass)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
@@ -199,7 +199,7 @@ i830StencilOpSeparate(GLcontext * ctx, GLenum face, GLenum fail, GLenum zfail,
|
||||
}
|
||||
|
||||
static void
|
||||
i830AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref)
|
||||
i830AlphaFunc(struct gl_context * ctx, GLenum func, GLfloat ref)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int test = intel_translate_compare_func(func);
|
||||
@@ -228,7 +228,7 @@ i830AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref)
|
||||
* I'm not sure which is correct.
|
||||
*/
|
||||
static void
|
||||
i830EvalLogicOpBlendState(GLcontext * ctx)
|
||||
i830EvalLogicOpBlendState(struct gl_context * ctx)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -255,7 +255,7 @@ i830EvalLogicOpBlendState(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i830BlendColor(GLcontext * ctx, const GLfloat color[4])
|
||||
i830BlendColor(struct gl_context * ctx, const GLfloat color[4])
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
GLubyte r, g, b, a;
|
||||
@@ -279,7 +279,7 @@ i830BlendColor(GLcontext * ctx, const GLfloat color[4])
|
||||
* change the interpretation of the blend function.
|
||||
*/
|
||||
static void
|
||||
i830_set_blend_state(GLcontext * ctx)
|
||||
i830_set_blend_state(struct gl_context * ctx)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int funcA;
|
||||
@@ -385,7 +385,7 @@ i830_set_blend_state(GLcontext * ctx)
|
||||
|
||||
|
||||
static void
|
||||
i830BlendEquationSeparate(GLcontext * ctx, GLenum modeRGB, GLenum modeA)
|
||||
i830BlendEquationSeparate(struct gl_context * ctx, GLenum modeRGB, GLenum modeA)
|
||||
{
|
||||
DBG("%s -> %s, %s\n", __FUNCTION__,
|
||||
_mesa_lookup_enum_by_nr(modeRGB),
|
||||
@@ -398,7 +398,7 @@ i830BlendEquationSeparate(GLcontext * ctx, GLenum modeRGB, GLenum modeA)
|
||||
|
||||
|
||||
static void
|
||||
i830BlendFuncSeparate(GLcontext * ctx, GLenum sfactorRGB,
|
||||
i830BlendFuncSeparate(struct gl_context * ctx, GLenum sfactorRGB,
|
||||
GLenum dfactorRGB, GLenum sfactorA, GLenum dfactorA)
|
||||
{
|
||||
DBG("%s -> RGB(%s, %s) A(%s, %s)\n", __FUNCTION__,
|
||||
@@ -417,7 +417,7 @@ i830BlendFuncSeparate(GLcontext * ctx, GLenum sfactorRGB,
|
||||
|
||||
|
||||
static void
|
||||
i830DepthFunc(GLcontext * ctx, GLenum func)
|
||||
i830DepthFunc(struct gl_context * ctx, GLenum func)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int test = intel_translate_compare_func(func);
|
||||
@@ -431,7 +431,7 @@ i830DepthFunc(GLcontext * ctx, GLenum func)
|
||||
}
|
||||
|
||||
static void
|
||||
i830DepthMask(GLcontext * ctx, GLboolean flag)
|
||||
i830DepthMask(struct gl_context * ctx, GLboolean flag)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -449,7 +449,7 @@ i830DepthMask(GLcontext * ctx, GLboolean flag)
|
||||
|
||||
/** Called from ctx->Driver.Viewport() */
|
||||
static void
|
||||
i830Viewport(GLcontext * ctx,
|
||||
i830Viewport(struct gl_context * ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height)
|
||||
{
|
||||
intelCalcViewport(ctx);
|
||||
@@ -458,7 +458,7 @@ i830Viewport(GLcontext * ctx,
|
||||
|
||||
/** Called from ctx->Driver.DepthRange() */
|
||||
static void
|
||||
i830DepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval)
|
||||
i830DepthRange(struct gl_context * ctx, GLclampd nearval, GLclampd farval)
|
||||
{
|
||||
intelCalcViewport(ctx);
|
||||
}
|
||||
@@ -470,7 +470,7 @@ i830DepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval)
|
||||
* Fortunately stipple is usually a repeating pattern.
|
||||
*/
|
||||
static void
|
||||
i830PolygonStipple(GLcontext * ctx, const GLubyte * mask)
|
||||
i830PolygonStipple(struct gl_context * ctx, const GLubyte * mask)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
const GLubyte *m = mask;
|
||||
@@ -526,7 +526,7 @@ i830PolygonStipple(GLcontext * ctx, const GLubyte * mask)
|
||||
* Hardware clipping
|
||||
*/
|
||||
static void
|
||||
i830Scissor(GLcontext * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
i830Scissor(struct gl_context * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int x1, y1, x2, y2;
|
||||
@@ -566,7 +566,7 @@ i830Scissor(GLcontext * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
}
|
||||
|
||||
static void
|
||||
i830LogicOp(GLcontext * ctx, GLenum opcode)
|
||||
i830LogicOp(struct gl_context * ctx, GLenum opcode)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int tmp = intel_translate_logic_op(opcode);
|
||||
@@ -581,7 +581,7 @@ i830LogicOp(GLcontext * ctx, GLenum opcode)
|
||||
|
||||
|
||||
static void
|
||||
i830CullFaceFrontFace(GLcontext * ctx, GLenum unused)
|
||||
i830CullFaceFrontFace(struct gl_context * ctx, GLenum unused)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
GLuint mode;
|
||||
@@ -609,7 +609,7 @@ i830CullFaceFrontFace(GLcontext * ctx, GLenum unused)
|
||||
}
|
||||
|
||||
static void
|
||||
i830LineWidth(GLcontext * ctx, GLfloat widthf)
|
||||
i830LineWidth(struct gl_context * ctx, GLfloat widthf)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
int width;
|
||||
@@ -630,7 +630,7 @@ i830LineWidth(GLcontext * ctx, GLfloat widthf)
|
||||
}
|
||||
|
||||
static void
|
||||
i830PointSize(GLcontext * ctx, GLfloat size)
|
||||
i830PointSize(struct gl_context * ctx, GLfloat size)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
GLint point_size = (int) size;
|
||||
@@ -650,7 +650,7 @@ i830PointSize(GLcontext * ctx, GLfloat size)
|
||||
*/
|
||||
|
||||
static void
|
||||
i830ColorMask(GLcontext * ctx,
|
||||
i830ColorMask(struct gl_context * ctx,
|
||||
GLboolean r, GLboolean g, GLboolean b, GLboolean a)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
@@ -672,7 +672,7 @@ i830ColorMask(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static void
|
||||
update_specular(GLcontext * ctx)
|
||||
update_specular(struct gl_context * ctx)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -686,7 +686,7 @@ update_specular(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i830LightModelfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
i830LightModelfv(struct gl_context * ctx, GLenum pname, const GLfloat * param)
|
||||
{
|
||||
DBG("%s\n", __FUNCTION__);
|
||||
|
||||
@@ -698,7 +698,7 @@ i830LightModelfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
/* In Mesa 3.5 we can reliably do native flatshading.
|
||||
*/
|
||||
static void
|
||||
i830ShadeModel(GLcontext * ctx, GLenum mode)
|
||||
i830ShadeModel(struct gl_context * ctx, GLenum mode)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
I830_STATECHANGE(i830, I830_UPLOAD_CTX);
|
||||
@@ -727,7 +727,7 @@ i830ShadeModel(GLcontext * ctx, GLenum mode)
|
||||
* Fog
|
||||
*/
|
||||
static void
|
||||
i830Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
i830Fogfv(struct gl_context * ctx, GLenum pname, const GLfloat * param)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -748,7 +748,7 @@ i830Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
*/
|
||||
|
||||
static void
|
||||
i830Enable(GLcontext * ctx, GLenum cap, GLboolean state)
|
||||
i830Enable(struct gl_context * ctx, GLenum cap, GLboolean state)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -1067,7 +1067,7 @@ i830_init_packets(struct i830_context *i830)
|
||||
}
|
||||
|
||||
void
|
||||
i830_update_provoking_vertex(GLcontext * ctx)
|
||||
i830_update_provoking_vertex(struct gl_context * ctx)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
|
||||
@@ -1119,7 +1119,7 @@ i830InitStateFuncs(struct dd_function_table *functions)
|
||||
void
|
||||
i830InitState(struct i830_context *i830)
|
||||
{
|
||||
GLcontext *ctx = &i830->intel.ctx;
|
||||
struct gl_context *ctx = &i830->intel.ctx;
|
||||
|
||||
i830_init_packets(i830);
|
||||
|
||||
|
||||
@@ -440,7 +440,7 @@ emit_passthrough(struct i830_context *i830)
|
||||
void
|
||||
i830EmitTextureBlend(struct i830_context *i830)
|
||||
{
|
||||
GLcontext *ctx = &i830->intel.ctx;
|
||||
struct gl_context *ctx = &i830->intel.ctx;
|
||||
GLuint unit, last_stage = 0, blendunit = 0;
|
||||
|
||||
I830_ACTIVESTATE(i830, I830_UPLOAD_TEXBLEND_ALL, GL_FALSE);
|
||||
|
||||
@@ -113,7 +113,7 @@ translate_wrap_mode(GLenum wrap)
|
||||
static GLboolean
|
||||
i830_update_tex_unit(struct intel_context *intel, GLuint unit, GLuint ss3)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
struct gl_texture_unit *tUnit = &ctx->Texture.Unit[unit];
|
||||
struct gl_texture_object *tObj = tUnit->_Current;
|
||||
|
||||
@@ -69,7 +69,7 @@ i830_render_prevalidate(struct intel_context *intel)
|
||||
static void
|
||||
i830_render_start(struct intel_context *intel)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct i830_context *i830 = i830_context(ctx);
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
struct vertex_buffer *VB = &tnl->vb;
|
||||
@@ -591,7 +591,7 @@ i830_set_draw_region(struct intel_context *intel,
|
||||
GLuint num_regions)
|
||||
{
|
||||
struct i830_context *i830 = i830_context(&intel->ctx);
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct gl_renderbuffer *rb = ctx->DrawBuffer->_ColorDrawBuffers[0];
|
||||
struct intel_renderbuffer *irb = intel_renderbuffer(rb);
|
||||
GLuint value;
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
/* Override intel default.
|
||||
*/
|
||||
static void
|
||||
i915InvalidateState(GLcontext * ctx, GLuint new_state)
|
||||
i915InvalidateState(struct gl_context * ctx, GLuint new_state)
|
||||
{
|
||||
_swrast_InvalidateState(ctx, new_state);
|
||||
_swsetup_InvalidateState(ctx, new_state);
|
||||
@@ -102,7 +102,7 @@ i915CreateContext(int api,
|
||||
struct i915_context *i915 =
|
||||
(struct i915_context *) CALLOC_STRUCT(i915_context);
|
||||
struct intel_context *intel = &i915->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
|
||||
if (!i915)
|
||||
return GL_FALSE;
|
||||
|
||||
@@ -158,7 +158,7 @@ struct i915_fragment_program
|
||||
/* TODO: split between the stored representation of a program and
|
||||
* the state used to build that representation.
|
||||
*/
|
||||
GLcontext *ctx;
|
||||
struct gl_context *ctx;
|
||||
|
||||
/* declarations contains the packet header. */
|
||||
GLuint declarations[I915_MAX_DECL_INSN * 3 + 1];
|
||||
@@ -337,9 +337,9 @@ extern void i915_print_ureg(const char *msg, GLuint ureg);
|
||||
*/
|
||||
extern void i915InitStateFunctions(struct dd_function_table *functions);
|
||||
extern void i915InitState(struct i915_context *i915);
|
||||
extern void i915_update_fog(GLcontext * ctx);
|
||||
extern void i915_update_stencil(GLcontext * ctx);
|
||||
extern void i915_update_provoking_vertex(GLcontext *ctx);
|
||||
extern void i915_update_fog(struct gl_context * ctx);
|
||||
extern void i915_update_stencil(struct gl_context * ctx);
|
||||
extern void i915_update_provoking_vertex(struct gl_context *ctx);
|
||||
|
||||
|
||||
/*======================================================================
|
||||
@@ -359,7 +359,7 @@ extern void i915InitFragProgFuncs(struct dd_function_table *functions);
|
||||
* macros used previously:
|
||||
*/
|
||||
static INLINE struct i915_context *
|
||||
i915_context(GLcontext * ctx)
|
||||
i915_context(struct gl_context * ctx)
|
||||
{
|
||||
return (struct i915_context *) ctx;
|
||||
}
|
||||
|
||||
@@ -1186,7 +1186,7 @@ track_params(struct i915_fragment_program *p)
|
||||
|
||||
|
||||
static void
|
||||
i915BindProgram(GLcontext * ctx, GLenum target, struct gl_program *prog)
|
||||
i915BindProgram(struct gl_context * ctx, GLenum target, struct gl_program *prog)
|
||||
{
|
||||
if (target == GL_FRAGMENT_PROGRAM_ARB) {
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
@@ -1209,7 +1209,7 @@ i915BindProgram(GLcontext * ctx, GLenum target, struct gl_program *prog)
|
||||
}
|
||||
|
||||
static struct gl_program *
|
||||
i915NewProgram(GLcontext * ctx, GLenum target, GLuint id)
|
||||
i915NewProgram(struct gl_context * ctx, GLenum target, GLuint id)
|
||||
{
|
||||
switch (target) {
|
||||
case GL_VERTEX_PROGRAM_ARB:
|
||||
@@ -1237,7 +1237,7 @@ i915NewProgram(GLcontext * ctx, GLenum target, GLuint id)
|
||||
}
|
||||
|
||||
static void
|
||||
i915DeleteProgram(GLcontext * ctx, struct gl_program *prog)
|
||||
i915DeleteProgram(struct gl_context * ctx, struct gl_program *prog)
|
||||
{
|
||||
if (prog->Target == GL_FRAGMENT_PROGRAM_ARB) {
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
@@ -1252,7 +1252,7 @@ i915DeleteProgram(GLcontext * ctx, struct gl_program *prog)
|
||||
|
||||
|
||||
static GLboolean
|
||||
i915IsProgramNative(GLcontext * ctx, GLenum target, struct gl_program *prog)
|
||||
i915IsProgramNative(struct gl_context * ctx, GLenum target, struct gl_program *prog)
|
||||
{
|
||||
if (target == GL_FRAGMENT_PROGRAM_ARB) {
|
||||
struct i915_fragment_program *p = (struct i915_fragment_program *) prog;
|
||||
@@ -1267,7 +1267,7 @@ i915IsProgramNative(GLcontext * ctx, GLenum target, struct gl_program *prog)
|
||||
}
|
||||
|
||||
static GLboolean
|
||||
i915ProgramStringNotify(GLcontext * ctx,
|
||||
i915ProgramStringNotify(struct gl_context * ctx,
|
||||
GLenum target, struct gl_program *prog)
|
||||
{
|
||||
if (target == GL_FRAGMENT_PROGRAM_ARB) {
|
||||
@@ -1291,7 +1291,7 @@ i915ProgramStringNotify(GLcontext * ctx,
|
||||
}
|
||||
|
||||
void
|
||||
i915_update_program(GLcontext *ctx)
|
||||
i915_update_program(struct gl_context *ctx)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
struct i915_context *i915 = i915_context(&intel->ctx);
|
||||
@@ -1316,7 +1316,7 @@ i915_update_program(GLcontext *ctx)
|
||||
void
|
||||
i915ValidateFragmentProgram(struct i915_context *i915)
|
||||
{
|
||||
GLcontext *ctx = &i915->intel.ctx;
|
||||
struct gl_context *ctx = &i915->intel.ctx;
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
struct vertex_buffer *VB = &tnl->vb;
|
||||
|
||||
@@ -457,7 +457,7 @@ i915_program_error(struct i915_fragment_program *p, const char *fmt, ...)
|
||||
void
|
||||
i915_init_program(struct i915_context *i915, struct i915_fragment_program *p)
|
||||
{
|
||||
GLcontext *ctx = &i915->intel.ctx;
|
||||
struct gl_context *ctx = &i915->intel.ctx;
|
||||
|
||||
p->translated = 0;
|
||||
p->params_uptodate = 0;
|
||||
|
||||
@@ -155,6 +155,6 @@ extern void i915_upload_program(struct i915_context *i915,
|
||||
|
||||
extern void i915_fini_program(struct i915_fragment_program *p);
|
||||
|
||||
extern void i915_update_program(GLcontext *ctx);
|
||||
extern void i915_update_program(struct gl_context *ctx);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
#define FILE_DEBUG_FLAG DEBUG_STATE
|
||||
|
||||
void
|
||||
i915_update_stencil(GLcontext * ctx)
|
||||
i915_update_stencil(struct gl_context * ctx)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
GLuint front_ref, front_writemask, front_mask;
|
||||
@@ -147,24 +147,24 @@ i915_update_stencil(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i915StencilFuncSeparate(GLcontext * ctx, GLenum face, GLenum func, GLint ref,
|
||||
i915StencilFuncSeparate(struct gl_context * ctx, GLenum face, GLenum func, GLint ref,
|
||||
GLuint mask)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
i915StencilMaskSeparate(GLcontext * ctx, GLenum face, GLuint mask)
|
||||
i915StencilMaskSeparate(struct gl_context * ctx, GLenum face, GLuint mask)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
i915StencilOpSeparate(GLcontext * ctx, GLenum face, GLenum fail, GLenum zfail,
|
||||
i915StencilOpSeparate(struct gl_context * ctx, GLenum face, GLenum fail, GLenum zfail,
|
||||
GLenum zpass)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
i915AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref)
|
||||
i915AlphaFunc(struct gl_context * ctx, GLenum func, GLfloat ref)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int test = intel_translate_compare_func(func);
|
||||
@@ -187,7 +187,7 @@ i915AlphaFunc(GLcontext * ctx, GLenum func, GLfloat ref)
|
||||
* calls to glEnable.
|
||||
*/
|
||||
static void
|
||||
i915EvalLogicOpBlendState(GLcontext * ctx)
|
||||
i915EvalLogicOpBlendState(struct gl_context * ctx)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -210,7 +210,7 @@ i915EvalLogicOpBlendState(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i915BlendColor(GLcontext * ctx, const GLfloat color[4])
|
||||
i915BlendColor(struct gl_context * ctx, const GLfloat color[4])
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
GLubyte r, g, b, a;
|
||||
@@ -255,7 +255,7 @@ translate_blend_equation(GLenum mode)
|
||||
}
|
||||
|
||||
static void
|
||||
i915UpdateBlendState(GLcontext * ctx)
|
||||
i915UpdateBlendState(struct gl_context * ctx)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
GLuint iab = (i915->state.Ctx[I915_CTXREG_IAB] &
|
||||
@@ -306,7 +306,7 @@ i915UpdateBlendState(GLcontext * ctx)
|
||||
|
||||
|
||||
static void
|
||||
i915BlendFuncSeparate(GLcontext * ctx, GLenum srcRGB,
|
||||
i915BlendFuncSeparate(struct gl_context * ctx, GLenum srcRGB,
|
||||
GLenum dstRGB, GLenum srcA, GLenum dstA)
|
||||
{
|
||||
i915UpdateBlendState(ctx);
|
||||
@@ -314,14 +314,14 @@ i915BlendFuncSeparate(GLcontext * ctx, GLenum srcRGB,
|
||||
|
||||
|
||||
static void
|
||||
i915BlendEquationSeparate(GLcontext * ctx, GLenum eqRGB, GLenum eqA)
|
||||
i915BlendEquationSeparate(struct gl_context * ctx, GLenum eqRGB, GLenum eqA)
|
||||
{
|
||||
i915UpdateBlendState(ctx);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
i915DepthFunc(GLcontext * ctx, GLenum func)
|
||||
i915DepthFunc(struct gl_context * ctx, GLenum func)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int test = intel_translate_compare_func(func);
|
||||
@@ -334,7 +334,7 @@ i915DepthFunc(GLcontext * ctx, GLenum func)
|
||||
}
|
||||
|
||||
static void
|
||||
i915DepthMask(GLcontext * ctx, GLboolean flag)
|
||||
i915DepthMask(struct gl_context * ctx, GLboolean flag)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -357,7 +357,7 @@ i915DepthMask(GLcontext * ctx, GLboolean flag)
|
||||
* - window pos/size or FBO size
|
||||
*/
|
||||
void
|
||||
intelCalcViewport(GLcontext * ctx)
|
||||
intelCalcViewport(struct gl_context * ctx)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
const GLfloat *v = ctx->Viewport._WindowMap.m;
|
||||
@@ -390,7 +390,7 @@ intelCalcViewport(GLcontext * ctx)
|
||||
|
||||
/** Called from ctx->Driver.Viewport() */
|
||||
static void
|
||||
i915Viewport(GLcontext * ctx,
|
||||
i915Viewport(struct gl_context * ctx,
|
||||
GLint x, GLint y, GLsizei width, GLsizei height)
|
||||
{
|
||||
intelCalcViewport(ctx);
|
||||
@@ -399,7 +399,7 @@ i915Viewport(GLcontext * ctx,
|
||||
|
||||
/** Called from ctx->Driver.DepthRange() */
|
||||
static void
|
||||
i915DepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval)
|
||||
i915DepthRange(struct gl_context * ctx, GLclampd nearval, GLclampd farval)
|
||||
{
|
||||
intelCalcViewport(ctx);
|
||||
}
|
||||
@@ -412,7 +412,7 @@ i915DepthRange(GLcontext * ctx, GLclampd nearval, GLclampd farval)
|
||||
* Fortunately stipple is usually a repeating pattern.
|
||||
*/
|
||||
static void
|
||||
i915PolygonStipple(GLcontext * ctx, const GLubyte * mask)
|
||||
i915PolygonStipple(struct gl_context * ctx, const GLubyte * mask)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
const GLubyte *m;
|
||||
@@ -474,7 +474,7 @@ i915PolygonStipple(GLcontext * ctx, const GLubyte * mask)
|
||||
* Hardware clipping
|
||||
*/
|
||||
static void
|
||||
i915Scissor(GLcontext * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
i915Scissor(struct gl_context * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int x1, y1, x2, y2;
|
||||
@@ -514,7 +514,7 @@ i915Scissor(GLcontext * ctx, GLint x, GLint y, GLsizei w, GLsizei h)
|
||||
}
|
||||
|
||||
static void
|
||||
i915LogicOp(GLcontext * ctx, GLenum opcode)
|
||||
i915LogicOp(struct gl_context * ctx, GLenum opcode)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int tmp = intel_translate_logic_op(opcode);
|
||||
@@ -529,7 +529,7 @@ i915LogicOp(GLcontext * ctx, GLenum opcode)
|
||||
|
||||
|
||||
static void
|
||||
i915CullFaceFrontFace(GLcontext * ctx, GLenum unused)
|
||||
i915CullFaceFrontFace(struct gl_context * ctx, GLenum unused)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
GLuint mode;
|
||||
@@ -560,7 +560,7 @@ i915CullFaceFrontFace(GLcontext * ctx, GLenum unused)
|
||||
}
|
||||
|
||||
static void
|
||||
i915LineWidth(GLcontext * ctx, GLfloat widthf)
|
||||
i915LineWidth(struct gl_context * ctx, GLfloat widthf)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int lis4 = i915->state.Ctx[I915_CTXREG_LIS4] & ~S4_LINE_WIDTH_MASK;
|
||||
@@ -579,7 +579,7 @@ i915LineWidth(GLcontext * ctx, GLfloat widthf)
|
||||
}
|
||||
|
||||
static void
|
||||
i915PointSize(GLcontext * ctx, GLfloat size)
|
||||
i915PointSize(struct gl_context * ctx, GLfloat size)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
int lis4 = i915->state.Ctx[I915_CTXREG_LIS4] & ~S4_POINT_WIDTH_MASK;
|
||||
@@ -598,7 +598,7 @@ i915PointSize(GLcontext * ctx, GLfloat size)
|
||||
|
||||
|
||||
static void
|
||||
i915PointParameterfv(GLcontext * ctx, GLenum pname, const GLfloat *params)
|
||||
i915PointParameterfv(struct gl_context * ctx, GLenum pname, const GLfloat *params)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -620,7 +620,7 @@ i915PointParameterfv(GLcontext * ctx, GLenum pname, const GLfloat *params)
|
||||
*/
|
||||
|
||||
static void
|
||||
i915ColorMask(GLcontext * ctx,
|
||||
i915ColorMask(struct gl_context * ctx,
|
||||
GLboolean r, GLboolean g, GLboolean b, GLboolean a)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
@@ -645,7 +645,7 @@ i915ColorMask(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static void
|
||||
update_specular(GLcontext * ctx)
|
||||
update_specular(struct gl_context * ctx)
|
||||
{
|
||||
/* A hack to trigger the rebuild of the fragment program.
|
||||
*/
|
||||
@@ -653,7 +653,7 @@ update_specular(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i915LightModelfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
i915LightModelfv(struct gl_context * ctx, GLenum pname, const GLfloat * param)
|
||||
{
|
||||
DBG("%s\n", __FUNCTION__);
|
||||
|
||||
@@ -663,7 +663,7 @@ i915LightModelfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
}
|
||||
|
||||
static void
|
||||
i915ShadeModel(GLcontext * ctx, GLenum mode)
|
||||
i915ShadeModel(struct gl_context * ctx, GLenum mode)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
I915_STATECHANGE(i915, I915_UPLOAD_CTX);
|
||||
@@ -684,7 +684,7 @@ i915ShadeModel(GLcontext * ctx, GLenum mode)
|
||||
* Fog
|
||||
*/
|
||||
void
|
||||
i915_update_fog(GLcontext * ctx)
|
||||
i915_update_fog(struct gl_context * ctx)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
GLenum mode;
|
||||
@@ -780,7 +780,7 @@ i915_update_fog(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
i915Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
i915Fogfv(struct gl_context * ctx, GLenum pname, const GLfloat * param)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -820,7 +820,7 @@ i915Fogfv(GLcontext * ctx, GLenum pname, const GLfloat * param)
|
||||
}
|
||||
|
||||
static void
|
||||
i915Hint(GLcontext * ctx, GLenum target, GLenum state)
|
||||
i915Hint(struct gl_context * ctx, GLenum target, GLenum state)
|
||||
{
|
||||
switch (target) {
|
||||
case GL_FOG_HINT:
|
||||
@@ -834,7 +834,7 @@ i915Hint(GLcontext * ctx, GLenum target, GLenum state)
|
||||
*/
|
||||
|
||||
static void
|
||||
i915Enable(GLcontext * ctx, GLenum cap, GLboolean state)
|
||||
i915Enable(struct gl_context * ctx, GLenum cap, GLboolean state)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -1093,7 +1093,7 @@ i915_init_packets(struct i915_context *i915)
|
||||
}
|
||||
|
||||
void
|
||||
i915_update_provoking_vertex(GLcontext * ctx)
|
||||
i915_update_provoking_vertex(struct gl_context * ctx)
|
||||
{
|
||||
struct i915_context *i915 = I915_CONTEXT(ctx);
|
||||
|
||||
@@ -1150,7 +1150,7 @@ i915InitStateFunctions(struct dd_function_table *functions)
|
||||
void
|
||||
i915InitState(struct i915_context *i915)
|
||||
{
|
||||
GLcontext *ctx = &i915->intel.ctx;
|
||||
struct gl_context *ctx = &i915->intel.ctx;
|
||||
|
||||
i915_init_packets(i915);
|
||||
|
||||
|
||||
@@ -130,7 +130,7 @@ translate_wrap_mode(GLenum wrap)
|
||||
static GLboolean
|
||||
i915_update_tex_unit(struct intel_context *intel, GLuint unit, GLuint ss3)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct i915_context *i915 = i915_context(ctx);
|
||||
struct gl_texture_unit *tUnit = &ctx->Texture.Unit[unit];
|
||||
struct gl_texture_object *tObj = tUnit->_Current;
|
||||
|
||||
@@ -530,7 +530,7 @@ i915_set_draw_region(struct intel_context *intel,
|
||||
GLuint num_regions)
|
||||
{
|
||||
struct i915_context *i915 = i915_context(&intel->ctx);
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct gl_renderbuffer *rb = ctx->DrawBuffer->_ColorDrawBuffers[0];
|
||||
struct intel_renderbuffer *irb = intel_renderbuffer(rb);
|
||||
GLuint value;
|
||||
|
||||
@@ -216,7 +216,7 @@ choose_render(struct intel_context *intel, struct vertex_buffer *VB)
|
||||
|
||||
|
||||
static GLboolean
|
||||
intel_run_render(GLcontext * ctx, struct tnl_pipeline_stage *stage)
|
||||
intel_run_render(struct gl_context * ctx, struct tnl_pipeline_stage *stage)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
|
||||
@@ -55,8 +55,8 @@
|
||||
#include "i830_context.h"
|
||||
#include "i830_reg.h"
|
||||
|
||||
static void intelRenderPrimitive(GLcontext * ctx, GLenum prim);
|
||||
static void intelRasterPrimitive(GLcontext * ctx, GLenum rprim,
|
||||
static void intelRenderPrimitive(struct gl_context * ctx, GLenum prim);
|
||||
static void intelRasterPrimitive(struct gl_context * ctx, GLenum rprim,
|
||||
GLuint hwprim);
|
||||
|
||||
static void
|
||||
@@ -427,7 +427,7 @@ intel_draw_point(struct intel_context *intel, intelVertexPtr v0)
|
||||
static void
|
||||
intel_atten_point(struct intel_context *intel, intelVertexPtr v0)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
GLfloat psz[4], col[4], restore_psz, restore_alpha;
|
||||
|
||||
_tnl_get_attr(ctx, v0, _TNL_ATTRIB_POINTSIZE, psz);
|
||||
@@ -784,7 +784,7 @@ static void
|
||||
intel_fallback_tri(struct intel_context *intel,
|
||||
intelVertex * v0, intelVertex * v1, intelVertex * v2)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
SWvertex v[3];
|
||||
|
||||
if (0)
|
||||
@@ -805,7 +805,7 @@ static void
|
||||
intel_fallback_line(struct intel_context *intel,
|
||||
intelVertex * v0, intelVertex * v1)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
SWvertex v[2];
|
||||
|
||||
if (0)
|
||||
@@ -824,7 +824,7 @@ static void
|
||||
intel_fallback_point(struct intel_context *intel,
|
||||
intelVertex * v0)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
SWvertex v[1];
|
||||
|
||||
if (0)
|
||||
@@ -877,7 +877,7 @@ intel_fallback_point(struct intel_context *intel,
|
||||
|
||||
|
||||
static void
|
||||
intelRenderClippedPoly(GLcontext * ctx, const GLuint * elts, GLuint n)
|
||||
intelRenderClippedPoly(struct gl_context * ctx, const GLuint * elts, GLuint n)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
@@ -901,7 +901,7 @@ intelRenderClippedPoly(GLcontext * ctx, const GLuint * elts, GLuint n)
|
||||
}
|
||||
|
||||
static void
|
||||
intelRenderClippedLine(GLcontext * ctx, GLuint ii, GLuint jj)
|
||||
intelRenderClippedLine(struct gl_context * ctx, GLuint ii, GLuint jj)
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
|
||||
@@ -909,7 +909,7 @@ intelRenderClippedLine(GLcontext * ctx, GLuint ii, GLuint jj)
|
||||
}
|
||||
|
||||
static void
|
||||
intelFastRenderClippedPoly(GLcontext * ctx, const GLuint * elts, GLuint n)
|
||||
intelFastRenderClippedPoly(struct gl_context * ctx, const GLuint * elts, GLuint n)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
const GLuint vertsize = intel->vertex_size;
|
||||
@@ -936,7 +936,7 @@ intelFastRenderClippedPoly(GLcontext * ctx, const GLuint * elts, GLuint n)
|
||||
#define ANY_RASTER_FLAGS (DD_TRI_LIGHT_TWOSIDE | DD_TRI_OFFSET | DD_TRI_UNFILLED)
|
||||
|
||||
void
|
||||
intelChooseRenderState(GLcontext * ctx)
|
||||
intelChooseRenderState(struct gl_context * ctx)
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
@@ -1049,7 +1049,7 @@ static const GLenum reduced_prim[GL_POLYGON + 1] = {
|
||||
|
||||
|
||||
static void
|
||||
intelRunPipeline(GLcontext * ctx)
|
||||
intelRunPipeline(struct gl_context * ctx)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -1079,7 +1079,7 @@ intelRunPipeline(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
intelRenderStart(GLcontext * ctx)
|
||||
intelRenderStart(struct gl_context * ctx)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -1089,7 +1089,7 @@ intelRenderStart(GLcontext * ctx)
|
||||
}
|
||||
|
||||
static void
|
||||
intelRenderFinish(GLcontext * ctx)
|
||||
intelRenderFinish(struct gl_context * ctx)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -1106,7 +1106,7 @@ intelRenderFinish(GLcontext * ctx)
|
||||
* primitive.
|
||||
*/
|
||||
static void
|
||||
intelRasterPrimitive(GLcontext * ctx, GLenum rprim, GLuint hwprim)
|
||||
intelRasterPrimitive(struct gl_context * ctx, GLenum rprim, GLuint hwprim)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -1129,7 +1129,7 @@ intelRasterPrimitive(GLcontext * ctx, GLenum rprim, GLuint hwprim)
|
||||
/*
|
||||
*/
|
||||
static void
|
||||
intelRenderPrimitive(GLcontext * ctx, GLenum prim)
|
||||
intelRenderPrimitive(struct gl_context * ctx, GLenum prim)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -1201,7 +1201,7 @@ getFallbackString(GLuint bit)
|
||||
void
|
||||
intelFallback(struct intel_context *intel, GLbitfield bit, GLboolean mode)
|
||||
{
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
const GLbitfield oldfallback = intel->Fallback;
|
||||
|
||||
@@ -1253,7 +1253,7 @@ union fi
|
||||
|
||||
|
||||
void
|
||||
intelInitTriFuncs(GLcontext * ctx)
|
||||
intelInitTriFuncs(struct gl_context * ctx)
|
||||
{
|
||||
TNLcontext *tnl = TNL_CONTEXT(ctx);
|
||||
static int firsttime = 1;
|
||||
|
||||
@@ -42,9 +42,9 @@
|
||||
_NEW_PROGRAM | \
|
||||
_NEW_POLYGONSTIPPLE)
|
||||
|
||||
extern void intelInitTriFuncs(GLcontext * ctx);
|
||||
extern void intelInitTriFuncs(struct gl_context * ctx);
|
||||
|
||||
extern void intelChooseRenderState(GLcontext * ctx);
|
||||
extern void intelChooseRenderState(struct gl_context * ctx);
|
||||
|
||||
void intel_set_prim(struct intel_context *intel, uint32_t prim);
|
||||
GLuint *intel_get_prim_space(struct intel_context *intel, unsigned int count);
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
void
|
||||
brw_update_cc_vp(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_cc_viewport ccv;
|
||||
|
||||
memset(&ccv, 0, sizeof(ccv));
|
||||
@@ -91,7 +91,7 @@ static void prepare_cc_unit(struct brw_context *brw)
|
||||
static void upload_cc_unit(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_cc_unit_state cc;
|
||||
void *map;
|
||||
|
||||
|
||||
@@ -159,7 +159,7 @@ static void compile_clip_prog( struct brw_context *brw,
|
||||
static void upload_clip_prog(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct brw_clip_prog_key key;
|
||||
|
||||
memset(&key, 0, sizeof(key));
|
||||
|
||||
@@ -49,7 +49,7 @@ struct brw_clip_unit_key {
|
||||
static void
|
||||
clip_unit_populate_key(struct brw_context *brw, struct brw_clip_unit_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
/* CACHE_NEW_CLIP_PROG */
|
||||
|
||||
@@ -64,7 +64,7 @@ GLboolean brwCreateContext( int api,
|
||||
struct dd_function_table functions;
|
||||
struct brw_context *brw = (struct brw_context *) CALLOC_STRUCT(brw_context);
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
unsigned i;
|
||||
|
||||
if (!brw) {
|
||||
|
||||
@@ -763,15 +763,15 @@ void brw_upload_cs_urb_state(struct brw_context *brw);
|
||||
int brw_disasm (FILE *file, struct brw_instruction *inst, int gen);
|
||||
|
||||
/* brw_state.c */
|
||||
void brw_enable(GLcontext * ctx, GLenum cap, GLboolean state);
|
||||
void brw_depth_range(GLcontext *ctx, GLclampd nearval, GLclampd farval);
|
||||
void brw_enable(struct gl_context * ctx, GLenum cap, GLboolean state);
|
||||
void brw_depth_range(struct gl_context *ctx, GLclampd nearval, GLclampd farval);
|
||||
|
||||
/*======================================================================
|
||||
* Inline conversion functions. These are better-typed than the
|
||||
* macros used previously:
|
||||
*/
|
||||
static INLINE struct brw_context *
|
||||
brw_context( GLcontext *ctx )
|
||||
brw_context( struct gl_context *ctx )
|
||||
{
|
||||
return (struct brw_context *)ctx;
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
*/
|
||||
static void calculate_curbe_offsets( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
/* CACHE_NEW_WM_PROG */
|
||||
const GLuint nr_fp_regs = (brw->wm.prog_data->nr_params + 15) / 16;
|
||||
|
||||
@@ -179,7 +179,7 @@ static GLfloat fixed_plane[6][4] = {
|
||||
*/
|
||||
static void prepare_constant_buffer(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const struct brw_vertex_program *vp =
|
||||
brw_vertex_program_const(brw->vertex_program);
|
||||
const GLuint sz = brw->curbe.total_size;
|
||||
|
||||
@@ -80,7 +80,7 @@ static const GLenum reduced_prim[GL_POLYGON+1] = {
|
||||
static GLuint brw_set_prim(struct brw_context *brw,
|
||||
const struct _mesa_prim *prim)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
GLenum mode = prim->mode;
|
||||
|
||||
if (INTEL_DEBUG & DEBUG_PRIMS)
|
||||
@@ -201,7 +201,7 @@ static GLboolean check_fallbacks( struct brw_context *brw,
|
||||
const struct _mesa_prim *prim,
|
||||
GLuint nr_prims )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
GLuint i;
|
||||
|
||||
/* XXX FIXME */
|
||||
@@ -300,7 +300,7 @@ static GLboolean check_fallbacks( struct brw_context *brw,
|
||||
/* May fail if out of video memory for texture or vbo upload, or on
|
||||
* fallback conditions.
|
||||
*/
|
||||
static GLboolean brw_try_draw_prims( GLcontext *ctx,
|
||||
static GLboolean brw_try_draw_prims( struct gl_context *ctx,
|
||||
const struct gl_client_array *arrays[],
|
||||
const struct _mesa_prim *prim,
|
||||
GLuint nr_prims,
|
||||
@@ -423,7 +423,7 @@ static GLboolean brw_try_draw_prims( GLcontext *ctx,
|
||||
return retval;
|
||||
}
|
||||
|
||||
void brw_draw_prims( GLcontext *ctx,
|
||||
void brw_draw_prims( struct gl_context *ctx,
|
||||
const struct gl_client_array *arrays[],
|
||||
const struct _mesa_prim *prim,
|
||||
GLuint nr_prims,
|
||||
@@ -467,7 +467,7 @@ void brw_draw_prims( GLcontext *ctx,
|
||||
|
||||
void brw_draw_init( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct vbo_context *vbo = vbo_context(ctx);
|
||||
|
||||
/* Register our drawing function:
|
||||
|
||||
@@ -28,13 +28,13 @@
|
||||
#ifndef BRW_DRAW_H
|
||||
#define BRW_DRAW_H
|
||||
|
||||
#include "main/mtypes.h" /* for GLcontext... */
|
||||
#include "main/mtypes.h" /* for struct gl_context... */
|
||||
#include "vbo/vbo.h"
|
||||
|
||||
struct brw_context;
|
||||
|
||||
|
||||
void brw_draw_prims( GLcontext *ctx,
|
||||
void brw_draw_prims( struct gl_context *ctx,
|
||||
const struct gl_client_array *arrays[],
|
||||
const struct _mesa_prim *prims,
|
||||
GLuint nr_prims,
|
||||
@@ -48,7 +48,7 @@ void brw_draw_destroy( struct brw_context *brw );
|
||||
|
||||
/* brw_draw_current.c
|
||||
*/
|
||||
void brw_init_current_values(GLcontext *ctx,
|
||||
void brw_init_current_values(struct gl_context *ctx,
|
||||
struct gl_client_array *arrays);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -313,7 +313,7 @@ copy_array_to_vbo_array( struct brw_context *brw,
|
||||
|
||||
static void brw_prepare_vertices(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
GLbitfield vs_inputs = brw->vs.prog_data->inputs_read;
|
||||
GLuint i;
|
||||
@@ -451,7 +451,7 @@ static void brw_prepare_vertices(struct brw_context *brw)
|
||||
|
||||
static void brw_emit_vertices(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
GLuint i;
|
||||
|
||||
@@ -583,7 +583,7 @@ const struct brw_tracked_state brw_vertices = {
|
||||
|
||||
static void brw_prepare_indices(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
const struct _mesa_index_buffer *index_buffer = brw->ib.ib;
|
||||
GLuint ib_size;
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
static GLboolean do_check_fallback(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
GLuint i;
|
||||
|
||||
if (brw->intel.no_rast) {
|
||||
|
||||
@@ -28,15 +28,15 @@
|
||||
#ifndef BRW_FALLBACK_H
|
||||
#define BRW_FALLBACK_H
|
||||
|
||||
#include "main/mtypes.h" /* for GLcontext... */
|
||||
#include "main/mtypes.h" /* for struct gl_context... */
|
||||
|
||||
struct brw_context;
|
||||
struct vbo_prim;
|
||||
|
||||
void brw_fallback( GLcontext *ctx );
|
||||
void brw_unfallback( GLcontext *ctx );
|
||||
void brw_fallback( struct gl_context *ctx );
|
||||
void brw_unfallback( struct gl_context *ctx );
|
||||
|
||||
void brw_loopback_vertex_list( GLcontext *ctx,
|
||||
void brw_loopback_vertex_list( struct gl_context *ctx,
|
||||
const GLfloat *buffer,
|
||||
const GLubyte *attrsz,
|
||||
const struct vbo_prim *prim,
|
||||
|
||||
@@ -52,7 +52,7 @@ static int using_new_fs = -1;
|
||||
static struct brw_reg brw_reg_from_fs_reg(class fs_reg *reg);
|
||||
|
||||
struct gl_shader *
|
||||
brw_new_shader(GLcontext *ctx, GLuint name, GLuint type)
|
||||
brw_new_shader(struct gl_context *ctx, GLuint name, GLuint type)
|
||||
{
|
||||
struct brw_shader *shader;
|
||||
|
||||
@@ -67,7 +67,7 @@ brw_new_shader(GLcontext *ctx, GLuint name, GLuint type)
|
||||
}
|
||||
|
||||
struct gl_shader_program *
|
||||
brw_new_shader_program(GLcontext *ctx, GLuint name)
|
||||
brw_new_shader_program(struct gl_context *ctx, GLuint name)
|
||||
{
|
||||
struct brw_shader_program *prog;
|
||||
prog = talloc_zero(NULL, struct brw_shader_program);
|
||||
@@ -79,7 +79,7 @@ brw_new_shader_program(GLcontext *ctx, GLuint name)
|
||||
}
|
||||
|
||||
GLboolean
|
||||
brw_compile_shader(GLcontext *ctx, struct gl_shader *shader)
|
||||
brw_compile_shader(struct gl_context *ctx, struct gl_shader *shader)
|
||||
{
|
||||
if (!_mesa_ir_compile_shader(ctx, shader))
|
||||
return GL_FALSE;
|
||||
@@ -88,7 +88,7 @@ brw_compile_shader(GLcontext *ctx, struct gl_shader *shader)
|
||||
}
|
||||
|
||||
GLboolean
|
||||
brw_link_shader(GLcontext *ctx, struct gl_shader_program *prog)
|
||||
brw_link_shader(struct gl_context *ctx, struct gl_shader_program *prog)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
|
||||
@@ -2958,7 +2958,7 @@ brw_wm_fs_emit(struct brw_context *brw, struct brw_wm_compile *c)
|
||||
{
|
||||
struct brw_compile *p = &c->func;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
struct brw_shader *shader = NULL;
|
||||
struct gl_shader_program *prog = ctx->Shader.CurrentProgram;
|
||||
|
||||
|
||||
@@ -375,7 +375,7 @@ public:
|
||||
struct brw_context *brw;
|
||||
const struct gl_fragment_program *fp;
|
||||
struct intel_context *intel;
|
||||
GLcontext *ctx;
|
||||
struct gl_context *ctx;
|
||||
struct brw_wm_compile *c;
|
||||
struct brw_compile *p;
|
||||
struct brw_shader *shader;
|
||||
|
||||
@@ -167,7 +167,7 @@ static const GLenum gs_prim[GL_POLYGON+1] = {
|
||||
static void populate_key( struct brw_context *brw,
|
||||
struct brw_gs_prog_key *key )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
/* CACHE_NEW_VS_PROG */
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
|
||||
static void upload_blend_constant_color(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_blend_constant_color bcc;
|
||||
|
||||
memset(&bcc, 0, sizeof(bcc));
|
||||
@@ -76,7 +76,7 @@ const struct brw_tracked_state brw_blend_constant_color = {
|
||||
static void upload_drawing_rect(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
|
||||
BEGIN_BATCH(4);
|
||||
OUT_BATCH(_3DSTATE_DRAWRECT_INFO_I965);
|
||||
@@ -335,7 +335,7 @@ const struct brw_tracked_state brw_depthbuffer = {
|
||||
|
||||
static void upload_polygon_stipple(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_polygon_stipple bps;
|
||||
GLuint i;
|
||||
|
||||
@@ -378,7 +378,7 @@ const struct brw_tracked_state brw_polygon_stipple = {
|
||||
|
||||
static void upload_polygon_stipple_offset(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_polygon_stipple_offset bpso;
|
||||
|
||||
memset(&bpso, 0, sizeof(bpso));
|
||||
@@ -449,7 +449,7 @@ const struct brw_tracked_state brw_aa_line_parameters = {
|
||||
|
||||
static void upload_line_stipple(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_line_stipple bls;
|
||||
GLfloat tmp;
|
||||
GLint tmpi;
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
#include "brw_context.h"
|
||||
#include "brw_wm.h"
|
||||
|
||||
static void brwBindProgram( GLcontext *ctx,
|
||||
static void brwBindProgram( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
struct gl_program *prog )
|
||||
{
|
||||
@@ -57,7 +57,7 @@ static void brwBindProgram( GLcontext *ctx,
|
||||
}
|
||||
}
|
||||
|
||||
static struct gl_program *brwNewProgram( GLcontext *ctx,
|
||||
static struct gl_program *brwNewProgram( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
GLuint id )
|
||||
{
|
||||
@@ -93,14 +93,14 @@ static struct gl_program *brwNewProgram( GLcontext *ctx,
|
||||
}
|
||||
}
|
||||
|
||||
static void brwDeleteProgram( GLcontext *ctx,
|
||||
static void brwDeleteProgram( struct gl_context *ctx,
|
||||
struct gl_program *prog )
|
||||
{
|
||||
_mesa_delete_program( ctx, prog );
|
||||
}
|
||||
|
||||
|
||||
static GLboolean brwIsProgramNative( GLcontext *ctx,
|
||||
static GLboolean brwIsProgramNative( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
struct gl_program *prog )
|
||||
{
|
||||
@@ -108,7 +108,7 @@ static GLboolean brwIsProgramNative( GLcontext *ctx,
|
||||
}
|
||||
|
||||
static void
|
||||
shader_error(GLcontext *ctx, struct gl_program *prog, const char *msg)
|
||||
shader_error(struct gl_context *ctx, struct gl_program *prog, const char *msg)
|
||||
{
|
||||
struct gl_shader_program *shader;
|
||||
|
||||
@@ -120,7 +120,7 @@ shader_error(GLcontext *ctx, struct gl_program *prog, const char *msg)
|
||||
}
|
||||
}
|
||||
|
||||
static GLboolean brwProgramStringNotify( GLcontext *ctx,
|
||||
static GLboolean brwProgramStringNotify( struct gl_context *ctx,
|
||||
GLenum target,
|
||||
struct gl_program *prog )
|
||||
{
|
||||
|
||||
@@ -72,7 +72,7 @@ brw_queryobj_get_results(struct brw_query_object *query)
|
||||
}
|
||||
|
||||
static struct gl_query_object *
|
||||
brw_new_query_object(GLcontext *ctx, GLuint id)
|
||||
brw_new_query_object(struct gl_context *ctx, GLuint id)
|
||||
{
|
||||
struct brw_query_object *query;
|
||||
|
||||
@@ -87,7 +87,7 @@ brw_new_query_object(GLcontext *ctx, GLuint id)
|
||||
}
|
||||
|
||||
static void
|
||||
brw_delete_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
brw_delete_query(struct gl_context *ctx, struct gl_query_object *q)
|
||||
{
|
||||
struct brw_query_object *query = (struct brw_query_object *)q;
|
||||
|
||||
@@ -96,7 +96,7 @@ brw_delete_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
}
|
||||
|
||||
static void
|
||||
brw_begin_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
brw_begin_query(struct gl_context *ctx, struct gl_query_object *q)
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
@@ -146,7 +146,7 @@ brw_begin_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
* Begin the ARB_occlusion_query query on a query object.
|
||||
*/
|
||||
static void
|
||||
brw_end_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
brw_end_query(struct gl_context *ctx, struct gl_query_object *q)
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
@@ -197,7 +197,7 @@ brw_end_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
}
|
||||
}
|
||||
|
||||
static void brw_wait_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
static void brw_wait_query(struct gl_context *ctx, struct gl_query_object *q)
|
||||
{
|
||||
struct brw_query_object *query = (struct brw_query_object *)q;
|
||||
|
||||
@@ -205,7 +205,7 @@ static void brw_wait_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
query->Base.Ready = GL_TRUE;
|
||||
}
|
||||
|
||||
static void brw_check_query(GLcontext *ctx, struct gl_query_object *q)
|
||||
static void brw_check_query(struct gl_context *ctx, struct gl_query_object *q)
|
||||
{
|
||||
struct brw_query_object *query = (struct brw_query_object *)q;
|
||||
|
||||
|
||||
@@ -132,7 +132,7 @@ static void compile_sf_prog( struct brw_context *brw,
|
||||
*/
|
||||
static void upload_sf_prog(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_sf_prog_key key;
|
||||
|
||||
memset(&key, 0, sizeof(key));
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
|
||||
static void upload_sf_vp(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const GLfloat depth_scale = 1.0F / ctx->DrawBuffer->_DepthMaxF;
|
||||
struct brw_sf_viewport sfv;
|
||||
GLfloat y_scale, y_bias;
|
||||
@@ -139,7 +139,7 @@ struct brw_sf_unit_key {
|
||||
static void
|
||||
sf_unit_populate_key(struct brw_context *brw, struct brw_sf_unit_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
/* CACHE_NEW_SF_PROG */
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
#include "brw_context.h"
|
||||
|
||||
void
|
||||
brw_enable(GLcontext *ctx, GLenum cap, GLboolean state)
|
||||
brw_enable(struct gl_context *ctx, GLenum cap, GLboolean state)
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
|
||||
@@ -40,7 +40,7 @@ brw_enable(GLcontext *ctx, GLenum cap, GLboolean state)
|
||||
}
|
||||
|
||||
void
|
||||
brw_depth_range(GLcontext *ctx, GLclampd nearval, GLclampd farval)
|
||||
brw_depth_range(struct gl_context *ctx, GLclampd nearval, GLclampd farval)
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
|
||||
|
||||
@@ -336,7 +336,7 @@ brw_print_dirty_count(struct dirty_bit_map *bit_map, int32_t bits)
|
||||
*/
|
||||
void brw_validate_state( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
struct brw_state_flags *state = &brw->state.dirty;
|
||||
GLuint i;
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
*/
|
||||
void brw_validate_textures( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
int i;
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ static void do_vs_prog( struct brw_context *brw,
|
||||
struct brw_vertex_program *vp,
|
||||
struct brw_vs_prog_key *key )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
GLuint program_size;
|
||||
const GLuint *program;
|
||||
struct brw_vs_compile c;
|
||||
@@ -115,7 +115,7 @@ static void do_vs_prog( struct brw_context *brw,
|
||||
|
||||
static void brw_upload_vs_prog(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct brw_vs_prog_key key;
|
||||
struct brw_vertex_program *vp =
|
||||
(struct brw_vertex_program *)brw->vertex_program;
|
||||
|
||||
@@ -190,7 +190,7 @@ static GLuint get_input_size(struct brw_context *brw,
|
||||
*/
|
||||
static void calc_wm_input_sizes( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
/* BRW_NEW_VERTEX_PROGRAM */
|
||||
const struct brw_vertex_program *vp =
|
||||
brw_vertex_program_const(brw->vertex_program);
|
||||
|
||||
@@ -51,7 +51,7 @@ struct brw_vs_unit_key {
|
||||
static void
|
||||
vs_unit_populate_key(struct brw_context *brw, struct brw_vs_unit_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
static void
|
||||
prepare_vs_constants(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
struct brw_vertex_program *vp =
|
||||
(struct brw_vertex_program *) brw->vertex_program;
|
||||
@@ -101,7 +101,7 @@ const struct brw_tracked_state brw_vs_constants = {
|
||||
* Sets brw->vs.surf_bo[surf] and brw->vp->const_buffer.
|
||||
*/
|
||||
static void
|
||||
brw_update_vs_constant_surface( GLcontext *ctx,
|
||||
brw_update_vs_constant_surface( struct gl_context *ctx,
|
||||
GLuint surf)
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
@@ -151,7 +151,7 @@ prepare_vs_surfaces(struct brw_context *brw)
|
||||
*/
|
||||
static void upload_vs_surfaces(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
uint32_t *bind;
|
||||
int i;
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ static void brw_wm_populate_key( struct brw_context *brw,
|
||||
struct brw_wm_prog_key *key )
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
/* BRW_NEW_FRAGMENT_PROGRAM */
|
||||
const struct brw_fragment_program *fp =
|
||||
(struct brw_fragment_program *)brw->fragment_program;
|
||||
|
||||
@@ -467,10 +467,10 @@ void emit_xpd(struct brw_compile *p,
|
||||
const struct brw_reg *arg0,
|
||||
const struct brw_reg *arg1);
|
||||
|
||||
GLboolean brw_compile_shader(GLcontext *ctx,
|
||||
GLboolean brw_compile_shader(struct gl_context *ctx,
|
||||
struct gl_shader *shader);
|
||||
GLboolean brw_link_shader(GLcontext *ctx, struct gl_shader_program *prog);
|
||||
struct gl_shader *brw_new_shader(GLcontext *ctx, GLuint name, GLuint type);
|
||||
struct gl_shader_program *brw_new_shader_program(GLcontext *ctx, GLuint name);
|
||||
GLboolean brw_link_shader(struct gl_context *ctx, struct gl_shader_program *prog);
|
||||
struct gl_shader *brw_new_shader(struct gl_context *ctx, GLuint name, GLuint type);
|
||||
struct gl_shader_program *brw_new_shader_program(struct gl_context *ctx, GLuint name);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -233,7 +233,7 @@ static void
|
||||
brw_wm_sampler_populate_key(struct brw_context *brw,
|
||||
struct wm_sampler_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
int unit;
|
||||
char *last_entry_end = ((char*)&key->sampler_count) +
|
||||
sizeof(key->sampler_count);
|
||||
@@ -301,7 +301,7 @@ brw_wm_sampler_populate_key(struct brw_context *brw,
|
||||
*/
|
||||
static void upload_wm_samplers( struct brw_context *brw )
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct wm_sampler_key key;
|
||||
int i, sampler_key_size;
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ struct brw_wm_unit_key {
|
||||
static void
|
||||
wm_unit_populate_key(struct brw_context *brw, struct brw_wm_unit_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const struct gl_fragment_program *fp = brw->fragment_program;
|
||||
const struct brw_fragment_program *bfp = (struct brw_fragment_program *) fp;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
|
||||
@@ -209,7 +209,7 @@ brw_set_surface_tiling(struct brw_surface_state *surf, uint32_t tiling)
|
||||
}
|
||||
|
||||
static void
|
||||
brw_update_texture_surface( GLcontext *ctx, GLuint unit )
|
||||
brw_update_texture_surface( struct gl_context *ctx, GLuint unit )
|
||||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
struct gl_texture_object *tObj = ctx->Texture.Unit[unit]._Current;
|
||||
@@ -315,7 +315,7 @@ brw_create_constant_surface(struct brw_context *brw,
|
||||
static void
|
||||
prepare_wm_constants(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
struct intel_context *intel = &brw->intel;
|
||||
struct brw_fragment_program *fp =
|
||||
(struct brw_fragment_program *) brw->fragment_program;
|
||||
@@ -407,7 +407,7 @@ brw_update_renderbuffer_surface(struct brw_context *brw,
|
||||
unsigned int unit)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
drm_intel_bo *region_bo = NULL;
|
||||
struct intel_renderbuffer *irb = intel_renderbuffer(rb);
|
||||
struct intel_region *region = irb ? irb->region : NULL;
|
||||
@@ -572,7 +572,7 @@ brw_update_renderbuffer_surface(struct brw_context *brw,
|
||||
static void
|
||||
prepare_wm_surfaces(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
int i;
|
||||
int nr_surfaces = 0;
|
||||
|
||||
@@ -619,7 +619,7 @@ prepare_wm_surfaces(struct brw_context *brw)
|
||||
static void
|
||||
upload_wm_surfaces(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
GLuint i;
|
||||
|
||||
/* _NEW_BUFFERS | _NEW_COLOR */
|
||||
|
||||
@@ -49,7 +49,7 @@ static void
|
||||
blend_state_populate_key(struct brw_context *brw,
|
||||
struct gen6_blend_state_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
@@ -181,7 +181,7 @@ static void
|
||||
color_calc_state_populate_key(struct brw_context *brw,
|
||||
struct gen6_color_calc_state_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ static void
|
||||
upload_clip_state(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
uint32_t depth_clamp = 0;
|
||||
uint32_t provoking;
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@ static void
|
||||
depth_stencil_state_populate_key(struct brw_context *brw,
|
||||
struct brw_depth_stencil_state_key *key)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const unsigned back = ctx->Stencil._BackFace;
|
||||
|
||||
memset(key, 0, sizeof(*key));
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
static void
|
||||
prepare_scissor_state(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const GLboolean render_to_fbo = (ctx->DrawBuffer->Name != 0);
|
||||
struct gen6_scissor_rect scissor;
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ static void
|
||||
upload_sf_state(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
/* CACHE_NEW_VS_PROG */
|
||||
uint32_t num_inputs = brw_count_bits(brw->vs.prog_data->outputs_written);
|
||||
uint32_t num_outputs = brw_count_bits(brw->fragment_program->Base.InputsRead);
|
||||
|
||||
@@ -65,7 +65,7 @@ const struct brw_tracked_state gen6_clip_vp = {
|
||||
static void
|
||||
prepare_sf_vp(struct brw_context *brw)
|
||||
{
|
||||
GLcontext *ctx = &brw->intel.ctx;
|
||||
struct gl_context *ctx = &brw->intel.ctx;
|
||||
const GLfloat depth_scale = 1.0F / ctx->DrawBuffer->_DepthMaxF;
|
||||
struct brw_sf_viewport sfv;
|
||||
GLfloat y_scale, y_bias;
|
||||
|
||||
@@ -37,7 +37,7 @@ static void
|
||||
upload_vs_state(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
const struct brw_vertex_program *vp =
|
||||
brw_vertex_program_const(brw->vertex_program);
|
||||
unsigned int nr_params = vp->program.Base.Parameters->NumParameters;
|
||||
|
||||
@@ -37,7 +37,7 @@ static void
|
||||
prepare_wm_constants(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
const struct brw_fragment_program *fp =
|
||||
brw_fragment_program_const(brw->fragment_program);
|
||||
|
||||
@@ -81,7 +81,7 @@ static void
|
||||
upload_wm_state(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
GLcontext *ctx = &intel->ctx;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
const struct brw_fragment_program *fp =
|
||||
brw_fragment_program_const(brw->fragment_program);
|
||||
uint32_t dw2, dw4, dw5, dw6;
|
||||
|
||||
@@ -210,7 +210,7 @@ intelEmitCopyBlit(struct intel_context *intel,
|
||||
* \param mask bitmask of BUFFER_BIT_* values indicating buffers to clear
|
||||
*/
|
||||
void
|
||||
intelClearWithBlit(GLcontext *ctx, GLbitfield mask)
|
||||
intelClearWithBlit(struct gl_context *ctx, GLbitfield mask)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
struct gl_framebuffer *fb = ctx->DrawBuffer;
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
extern void intelCopyBuffer(const __DRIdrawable * dpriv,
|
||||
const drm_clip_rect_t * rect);
|
||||
|
||||
extern void intelClearWithBlit(GLcontext * ctx, GLbitfield mask);
|
||||
extern void intelClearWithBlit(struct gl_context * ctx, GLbitfield mask);
|
||||
|
||||
GLboolean
|
||||
intelEmitCopyBlit(struct intel_context *intel,
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#include "intel_regions.h"
|
||||
|
||||
static GLboolean
|
||||
intel_bufferobj_unmap(GLcontext * ctx,
|
||||
intel_bufferobj_unmap(struct gl_context * ctx,
|
||||
GLenum target, struct gl_buffer_object *obj);
|
||||
|
||||
/** Allocates a new drm_intel_bo to store the data for the buffer object. */
|
||||
@@ -59,7 +59,7 @@ intel_bufferobj_alloc_buffer(struct intel_context *intel,
|
||||
* internal structure where somehow shared.
|
||||
*/
|
||||
static struct gl_buffer_object *
|
||||
intel_bufferobj_alloc(GLcontext * ctx, GLuint name, GLenum target)
|
||||
intel_bufferobj_alloc(struct gl_context * ctx, GLuint name, GLenum target)
|
||||
{
|
||||
struct intel_buffer_object *obj = CALLOC_STRUCT(intel_buffer_object);
|
||||
|
||||
@@ -101,7 +101,7 @@ intel_bufferobj_cow(struct intel_context *intel,
|
||||
* Called via glDeleteBuffersARB().
|
||||
*/
|
||||
static void
|
||||
intel_bufferobj_free(GLcontext * ctx, struct gl_buffer_object *obj)
|
||||
intel_bufferobj_free(struct gl_context * ctx, struct gl_buffer_object *obj)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
struct intel_buffer_object *intel_obj = intel_buffer_object(obj);
|
||||
@@ -136,7 +136,7 @@ intel_bufferobj_free(GLcontext * ctx, struct gl_buffer_object *obj)
|
||||
* \return GL_TRUE for success, GL_FALSE if out of memory
|
||||
*/
|
||||
static GLboolean
|
||||
intel_bufferobj_data(GLcontext * ctx,
|
||||
intel_bufferobj_data(struct gl_context * ctx,
|
||||
GLenum target,
|
||||
GLsizeiptrARB size,
|
||||
const GLvoid * data,
|
||||
@@ -193,7 +193,7 @@ intel_bufferobj_data(GLcontext * ctx,
|
||||
* Called via glBufferSubDataARB().
|
||||
*/
|
||||
static void
|
||||
intel_bufferobj_subdata(GLcontext * ctx,
|
||||
intel_bufferobj_subdata(struct gl_context * ctx,
|
||||
GLenum target,
|
||||
GLintptrARB offset,
|
||||
GLsizeiptrARB size,
|
||||
@@ -239,7 +239,7 @@ intel_bufferobj_subdata(GLcontext * ctx,
|
||||
* Called via glGetBufferSubDataARB().
|
||||
*/
|
||||
static void
|
||||
intel_bufferobj_get_subdata(GLcontext * ctx,
|
||||
intel_bufferobj_get_subdata(struct gl_context * ctx,
|
||||
GLenum target,
|
||||
GLintptrARB offset,
|
||||
GLsizeiptrARB size,
|
||||
@@ -260,7 +260,7 @@ intel_bufferobj_get_subdata(GLcontext * ctx,
|
||||
* Called via glMapBufferARB().
|
||||
*/
|
||||
static void *
|
||||
intel_bufferobj_map(GLcontext * ctx,
|
||||
intel_bufferobj_map(struct gl_context * ctx,
|
||||
GLenum target,
|
||||
GLenum access, struct gl_buffer_object *obj)
|
||||
{
|
||||
@@ -322,7 +322,7 @@ intel_bufferobj_map(GLcontext * ctx,
|
||||
* and blit it into the real BO at unmap time.
|
||||
*/
|
||||
static void *
|
||||
intel_bufferobj_map_range(GLcontext * ctx,
|
||||
intel_bufferobj_map_range(struct gl_context * ctx,
|
||||
GLenum target, GLintptr offset, GLsizeiptr length,
|
||||
GLbitfield access, struct gl_buffer_object *obj)
|
||||
{
|
||||
@@ -415,7 +415,7 @@ intel_bufferobj_map_range(GLcontext * ctx,
|
||||
* would defeat the point.
|
||||
*/
|
||||
static void
|
||||
intel_bufferobj_flush_mapped_range(GLcontext *ctx, GLenum target,
|
||||
intel_bufferobj_flush_mapped_range(struct gl_context *ctx, GLenum target,
|
||||
GLintptr offset, GLsizeiptr length,
|
||||
struct gl_buffer_object *obj)
|
||||
{
|
||||
@@ -449,7 +449,7 @@ intel_bufferobj_flush_mapped_range(GLcontext *ctx, GLenum target,
|
||||
* Called via glUnmapBuffer().
|
||||
*/
|
||||
static GLboolean
|
||||
intel_bufferobj_unmap(GLcontext * ctx,
|
||||
intel_bufferobj_unmap(struct gl_context * ctx,
|
||||
GLenum target, struct gl_buffer_object *obj)
|
||||
{
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
@@ -537,7 +537,7 @@ intel_bufferobj_buffer(struct intel_context *intel,
|
||||
}
|
||||
|
||||
static void
|
||||
intel_bufferobj_copy_subdata(GLcontext *ctx,
|
||||
intel_bufferobj_copy_subdata(struct gl_context *ctx,
|
||||
struct gl_buffer_object *src,
|
||||
struct gl_buffer_object *dst,
|
||||
GLintptr read_offset, GLintptr write_offset,
|
||||
@@ -596,7 +596,7 @@ intel_bufferobj_copy_subdata(GLcontext *ctx,
|
||||
|
||||
#if FEATURE_APPLE_object_purgeable
|
||||
static GLenum
|
||||
intel_buffer_purgeable(GLcontext * ctx,
|
||||
intel_buffer_purgeable(struct gl_context * ctx,
|
||||
drm_intel_bo *buffer,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -609,7 +609,7 @@ intel_buffer_purgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_buffer_object_purgeable(GLcontext * ctx,
|
||||
intel_buffer_object_purgeable(struct gl_context * ctx,
|
||||
struct gl_buffer_object *obj,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -636,7 +636,7 @@ intel_buffer_object_purgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_texture_object_purgeable(GLcontext * ctx,
|
||||
intel_texture_object_purgeable(struct gl_context * ctx,
|
||||
struct gl_texture_object *obj,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -650,7 +650,7 @@ intel_texture_object_purgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_render_object_purgeable(GLcontext * ctx,
|
||||
intel_render_object_purgeable(struct gl_context * ctx,
|
||||
struct gl_renderbuffer *obj,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -664,7 +664,7 @@ intel_render_object_purgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_buffer_unpurgeable(GLcontext * ctx,
|
||||
intel_buffer_unpurgeable(struct gl_context * ctx,
|
||||
drm_intel_bo *buffer,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -678,7 +678,7 @@ intel_buffer_unpurgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_buffer_object_unpurgeable(GLcontext * ctx,
|
||||
intel_buffer_object_unpurgeable(struct gl_context * ctx,
|
||||
struct gl_buffer_object *obj,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -686,7 +686,7 @@ intel_buffer_object_unpurgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_texture_object_unpurgeable(GLcontext * ctx,
|
||||
intel_texture_object_unpurgeable(struct gl_context * ctx,
|
||||
struct gl_texture_object *obj,
|
||||
GLenum option)
|
||||
{
|
||||
@@ -700,7 +700,7 @@ intel_texture_object_unpurgeable(GLcontext * ctx,
|
||||
}
|
||||
|
||||
static GLenum
|
||||
intel_render_object_unpurgeable(GLcontext * ctx,
|
||||
intel_render_object_unpurgeable(struct gl_context * ctx,
|
||||
struct gl_renderbuffer *obj,
|
||||
GLenum option)
|
||||
{
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user