diff options
author | Ton Roosendaal <ton@blender.org> | 2012-11-10 15:55:45 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2012-11-10 15:55:45 +0400 |
commit | 4121e4b7e7420bfafe218da501162c8eae22a158 (patch) | |
tree | a3ec177e1cc7e3d31bd5716c008085a657448c4f /source/blender/editors | |
parent | 250109f5ace8471451a6d8bda8f67ffc955eb4b7 (diff) |
Added UI support to set OpenGL MultiSample.
Code to support it was lying around for long already, but not controlled by UI nicely.
Now you have in user preferences "System" tab an option to set it.
NOTE:
- it only works saving as User startup.blend, and restart Blender.
- your system should support it, no check for it is visible in UI
- tested only on iMac OSX 10.7
Screenshot:
http://www.blender.org/bf/chinchilla.blend.png
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_draw.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/space_view3d/view3d_draw.c b/source/blender/editors/space_view3d/view3d_draw.c index db74179b569..24fc6adae6d 100644 --- a/source/blender/editors/space_view3d/view3d_draw.c +++ b/source/blender/editors/space_view3d/view3d_draw.c @@ -2985,10 +2985,10 @@ static void view3d_main_area_draw_objects(const bContext *C, ARegion *ar, const v3d->zbuf = FALSE; /* enables anti-aliasing for 3D view drawing */ -#if 0 - if (!(U.gameflags & USER_DISABLE_AA)) - glEnable(GL_MULTISAMPLE_ARB); -#endif + if (U.ogl_multisamples) + if (!(U.gameflags & USER_DISABLE_AA)) + glEnable(GL_MULTISAMPLE_ARB); + /* needs to be done always, gridview is adjusted in drawgrid() now */ rv3d->gridview = v3d->grid; @@ -3101,12 +3101,12 @@ static void view3d_main_area_draw_objects(const bContext *C, ARegion *ar, const BIF_draw_manipulator(C); -#if 0 /* Disable back anti-aliasing */ - if (!(U.gameflags & USER_DISABLE_AA)) - glDisable(GL_MULTISAMPLE_ARB); -#endif + if (U.ogl_multisamples) + if (!(U.gameflags & USER_DISABLE_AA)) + glDisable(GL_MULTISAMPLE_ARB); + if (v3d->zbuf) { v3d->zbuf = FALSE; glDisable(GL_DEPTH_TEST); |