diff options
author | Ben Skeggs <skeggsb@gmail.com> | 2008-01-16 13:41:50 +1100 |
---|---|---|
committer | Ben Skeggs <skeggsb@gmail.com> | 2008-01-16 13:45:31 +1100 |
commit | e0e9326bdadb268dbb5eeedb14404ac2f48c103e (patch) | |
tree | cad1807addb4f13a50785dadc9f49854e94e0436 /src/mesa/pipe/nv40/nv40_context.h | |
parent | bc1ca3793d661de343b956d66ef70605d7de2dbb (diff) |
nv40: stronger type safety
Diffstat (limited to 'src/mesa/pipe/nv40/nv40_context.h')
-rw-r--r-- | src/mesa/pipe/nv40/nv40_context.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mesa/pipe/nv40/nv40_context.h b/src/mesa/pipe/nv40/nv40_context.h index 86aebbb927..b505efab54 100644 --- a/src/mesa/pipe/nv40/nv40_context.h +++ b/src/mesa/pipe/nv40/nv40_context.h @@ -82,7 +82,12 @@ struct nv40_context { struct pipe_vertex_buffer vtxbuf[PIPE_ATTRIB_MAX]; struct pipe_vertex_element vtxelt[PIPE_ATTRIB_MAX]; }; -#define nv40_context(ctx) ((struct nv40_context *)(ctx)) + +static inline struct nv40_context * +nv40_context(struct pipe_context *pipe) +{ + return (struct nv40_context *)pipe; +} extern void nv40_init_state_functions(struct nv40_context *nv40); extern void nv40_init_surface_functions(struct nv40_context *nv40); |