diff options
author | Marek Olšák <[email protected]> | 2012-12-03 05:36:08 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2012-12-07 14:19:29 +0100 |
commit | 35840ab189595b817fa8b1a1df8cc92474a7c38d (patch) | |
tree | 8c24773dedcfc0663c1388ed77ba30dc34212ed6 /src/mesa/state_tracker/st_manager.c | |
parent | 919f788b92362676fa368d9950532f82f762cdfb (diff) |
st/dri: implement MSAA for GLX/DRI2 framebuffers
All MSAA buffers are allocated privately and resolved into the DRI-provided
back and front buffers.
If an MSAA visual is chosen, the buffers st/mesa receives are all
multi-sample. st/mesa doesn't have access to the single-sample buffers
in that case.
This makes MSAA work in games like Nexuiz.
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_manager.c')
-rw-r--r-- | src/mesa/state_tracker/st_manager.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_manager.c b/src/mesa/state_tracker/st_manager.c index da581861479..b065db0acdf 100644 --- a/src/mesa/state_tracker/st_manager.c +++ b/src/mesa/state_tracker/st_manager.c @@ -398,7 +398,7 @@ st_visual_to_context_mode(const struct st_visual *visual, UTIL_FORMAT_COLORSPACE_RGB, 3); } - if (visual->samples) { + if (visual->samples > 1) { mode->sampleBuffers = 1; mode->samples = visual->samples; } @@ -899,7 +899,7 @@ static const struct st_api st_gl_api = { ST_PROFILE_OPENGL_ES2_MASK | #endif 0, - 0, + ST_API_FEATURE_MS_VISUALS_MASK, st_api_destroy, st_api_get_proc_address, st_api_create_context, |