[Bf-blender-cvs] [962ce2a] wiggly-widgets: Fix wrongly scaled arrow widgets while zooming

Julian Eisel noreply at git.blender.org
Fri Jul 24 15:00:13 CEST 2015


Commit: 962ce2a550032b648da2a60e39e6f86150ccc427
Author: Julian Eisel
Date:   Fri Jul 24 14:54:01 2015 +0200
Branches: wiggly-widgets
https://developer.blender.org/rB962ce2a550032b648da2a60e39e6f86150ccc427

Fix wrongly scaled arrow widgets while zooming

View matrix needs to be updated before using it (always used matrix from last redraw)

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

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

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

diff --git a/source/blender/windowmanager/intern/wm_widgets.c b/source/blender/windowmanager/intern/wm_widgets.c
index 53bc544..d07a8d5 100644
--- a/source/blender/windowmanager/intern/wm_widgets.c
+++ b/source/blender/windowmanager/intern/wm_widgets.c
@@ -236,7 +236,10 @@ static void widget_calculate_scale(wmWidget *widget, const bContext *C)
 {
 	float scale = 1.0f;
 	RegionView3D *rv3d = CTX_wm_region_view3d(C);
+
 	if (rv3d && !(U.tw_flag & V3D_3D_WIDGETS) && (widget->flag & WM_WIDGET_SCALE_3D)) {
+		ED_view3d_update_viewmat(CTX_data_scene(C), CTX_wm_view3d(C), CTX_wm_region(C), NULL, NULL);
+
 		if (widget->get_final_position) {
 			float position[3];




More information about the Bf-blender-cvs mailing list