[Bf-blender-cvs] [54b8241] master: Multi-View: Some Stereo 3D modes require a special drawing all the time

Dalai Felinto noreply at git.blender.org
Sat Jun 13 16:29:41 CEST 2015


Commit: 54b824106b68ba9850569d4052db97d54a109ac5
Author: Dalai Felinto
Date:   Sat Jun 13 11:23:01 2015 -0300
Branches: master
https://developer.blender.org/rB54b824106b68ba9850569d4052db97d54a109ac5

Multi-View: Some Stereo 3D modes require a special drawing all the time

some 3d methods change the window arrangment, thus they shouldn't
toggle on/off just because there is no 3d elements being drawn

The optimized solution would be to draw only the left eye in those
cases, but there is some issue going on with that, so this commit will
do for now.

===================================================================

M	source/blender/windowmanager/intern/wm_stereo.c

===================================================================

diff --git a/source/blender/windowmanager/intern/wm_stereo.c b/source/blender/windowmanager/intern/wm_stereo.c
index 639c6c1..1356751 100644
--- a/source/blender/windowmanager/intern/wm_stereo.c
+++ b/source/blender/windowmanager/intern/wm_stereo.c
@@ -370,14 +370,20 @@ bool WM_stereo3d_enabled(wmWindow *win, bool skip_stereo3d_check)
 {
 	bScreen *screen = win->screen;
 
+	/* some 3d methods change the window arrangment, thus they shouldn't
+	 * toggle on/off just because there is no 3d elements being drawn */
+	if (wm_stereo3d_is_fullscreen_required(win->stereo3d_format->display_mode)) {
+		return GHOST_GetWindowState(win->ghostwin) == GHOST_kWindowStateFullScreen;
+	}
+
 	if ((skip_stereo3d_check == false) && (ED_screen_stereo3d_required(screen) == false)) {
 		return false;
 	}
 
+	/* some 3d methods change the window arrangment, thus they shouldn't
+	 * toggle on/off just because there is no 3d elements being drawn */
 	if (wm_stereo3d_is_fullscreen_required(win->stereo3d_format->display_mode)) {
-		if (GHOST_GetWindowState(win->ghostwin) != GHOST_kWindowStateFullScreen) {
-			return false;
-		}
+		return GHOST_GetWindowState(win->ghostwin) == GHOST_kWindowStateFullScreen;
 	}
 
 	return true;




More information about the Bf-blender-cvs mailing list