[Mesa-dev] [PATCH 5/8] st/mesa: pass the configuration options to st_init_extensions
Vadim Girlin
vadimgirlin at gmail.com
Mon Apr 9 08:32:36 PDT 2012
Signed-off-by: Vadim Girlin <vadimgirlin at gmail.com>
---
src/mesa/state_tracker/st_context.c | 9 +++++----
src/mesa/state_tracker/st_context.h | 3 ++-
src/mesa/state_tracker/st_extensions.c | 2 +-
src/mesa/state_tracker/st_extensions.h | 2 +-
src/mesa/state_tracker/st_manager.c | 2 +-
5 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c
index a3fd4db..1e76501 100644
--- a/src/mesa/state_tracker/st_context.c
+++ b/src/mesa/state_tracker/st_context.c
@@ -111,7 +111,7 @@ st_get_msaa(void)
static struct st_context *
-st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe )
+st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe, const driOptionCache * optionCache )
{
uint i;
struct st_context *st = ST_CALLOC_STRUCT( st_context );
@@ -171,7 +171,7 @@ st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe )
/* GL limits and extensions */
st_init_limits(st);
- st_init_extensions(st);
+ st_init_extensions(st, optionCache);
return st;
}
@@ -179,7 +179,8 @@ st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe )
struct st_context *st_create_context(gl_api api, struct pipe_context *pipe,
const struct gl_config *visual,
- struct st_context *share)
+ struct st_context *share,
+ const driOptionCache * optionCache)
{
struct gl_context *ctx;
struct gl_context *shareCtx = share ? share->ctx : NULL;
@@ -204,7 +205,7 @@ struct st_context *st_create_context(gl_api api, struct pipe_context *pipe,
if (debug_get_option_mesa_mvp_dp4())
_mesa_set_mvp_with_dp4( ctx, GL_TRUE );
- return st_create_context_priv(ctx, pipe);
+ return st_create_context_priv(ctx, pipe, optionCache);
}
diff --git a/src/mesa/state_tracker/st_context.h b/src/mesa/state_tracker/st_context.h
index da03719..b9a229a 100644
--- a/src/mesa/state_tracker/st_context.h
+++ b/src/mesa/state_tracker/st_context.h
@@ -281,7 +281,8 @@ st_get_msaa(void);
extern struct st_context *
st_create_context(gl_api api, struct pipe_context *pipe,
const struct gl_config *visual,
- struct st_context *share);
+ struct st_context *share,
+ const driOptionCache * optionCache);
extern void
st_destroy_context(struct st_context *st);
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c
index afea0ea..0c98611 100644
--- a/src/mesa/state_tracker/st_extensions.c
+++ b/src/mesa/state_tracker/st_extensions.c
@@ -325,7 +325,7 @@ static void init_format_extensions(struct st_context *st,
* features or can be built on top of other gallium features.
* Some fine tuning may still be needed.
*/
-void st_init_extensions(struct st_context *st)
+void st_init_extensions(struct st_context *st, const driOptionCache * optionCache)
{
struct pipe_screen *screen = st->pipe->screen;
struct gl_context *ctx = st->ctx;
diff --git a/src/mesa/state_tracker/st_extensions.h b/src/mesa/state_tracker/st_extensions.h
index aa9b2b2..bb79336 100644
--- a/src/mesa/state_tracker/st_extensions.h
+++ b/src/mesa/state_tracker/st_extensions.h
@@ -34,7 +34,7 @@ struct st_context;
extern void st_init_limits(struct st_context *st);
-extern void st_init_extensions(struct st_context *st);
+extern void st_init_extensions(struct st_context *st, const driOptionCache * optionCache);
#endif /* ST_EXTENSIONS_H */
diff --git a/src/mesa/state_tracker/st_manager.c b/src/mesa/state_tracker/st_manager.c
index d54b7ed..c0c3f1a 100644
--- a/src/mesa/state_tracker/st_manager.c
+++ b/src/mesa/state_tracker/st_manager.c
@@ -635,7 +635,7 @@ st_api_create_context(struct st_api *stapi, struct st_manager *smapi,
}
st_visual_to_context_mode(&attribs->visual, &mode);
- st = st_create_context(api, pipe, &mode, shared_ctx);
+ st = st_create_context(api, pipe, &mode, shared_ctx, attribs->optionCache);
if (!st) {
*error = ST_CONTEXT_ERROR_NO_MEMORY;
pipe->destroy(pipe);
--
1.7.7.6
More information about the mesa-dev
mailing list