diff options
author | Vadim Girlin <[email protected]> | 2012-04-09 19:35:39 +0400 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2012-04-20 17:43:24 +0100 |
commit | e382a0c14251a3000090ee75765f8d88d1b20409 (patch) | |
tree | 6664a763db681dd91d5286a90c64821a514c7ee3 | |
parent | b0e048f0b955ef79e2de794172de053d27d7d8fa (diff) |
r600g: store glsl_feature_level in the r600_screen
Signed-off-by: Vadim Girlin <[email protected]>
Reviewed-by: Michel Dänzer <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
-rw-r--r-- | src/gallium/drivers/r600/r600_pipe.c | 3 | ||||
-rw-r--r-- | src/gallium/drivers/r600/r600_pipe.h | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index 49c79f16ffa..b1bb26a0227 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -405,7 +405,7 @@ static int r600_get_param(struct pipe_screen* pscreen, enum pipe_cap param) return 1; case PIPE_CAP_GLSL_FEATURE_LEVEL: - return debug_get_bool_option("R600_GLSL130", FALSE) ? 130 : 120; + return rscreen->glsl_feature_level; /* Supported except the original R600. */ case PIPE_CAP_INDEP_BLEND_ENABLE: @@ -875,6 +875,7 @@ struct pipe_screen *r600_screen_create(struct radeon_winsys *ws) pipe_mutex_init(rscreen->fences.mutex); rscreen->use_surface_alloc = debug_get_bool_option("R600_SURF", TRUE); + rscreen->glsl_feature_level = debug_get_bool_option("R600_GLSL130", FALSE) ? 130 : 120; return &rscreen->screen; } diff --git a/src/gallium/drivers/r600/r600_pipe.h b/src/gallium/drivers/r600/r600_pipe.h index fafc4364043..fd134fae0c6 100644 --- a/src/gallium/drivers/r600/r600_pipe.h +++ b/src/gallium/drivers/r600/r600_pipe.h @@ -124,6 +124,7 @@ struct r600_screen { unsigned num_contexts; bool use_surface_alloc; + int glsl_feature_level; /* for thread-safe write accessing to num_contexts */ pipe_mutex mutex_num_contexts; |