diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-02-04 14:17:01 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-02-04 14:19:28 +0300 |
commit | 3dde6360ff6ae002002472f7b5a155e3d119230f (patch) | |
tree | 802493f801cad87d93f53e20173a02e671a3def4 /source/blender/windowmanager | |
parent | 62dba60e49e79e77ecb11027e723823767c13854 (diff) |
Fix T65306: UI widgets clipped when scaled up
Normal UI widget and 3D navigation gizmo where clipping at high DPI.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r-- | source/blender/windowmanager/intern/wm_subwindow.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/windowmanager/intern/wm_subwindow.c b/source/blender/windowmanager/intern/wm_subwindow.c index 6a5de84ac31..5ef78723a2a 100644 --- a/source/blender/windowmanager/intern/wm_subwindow.c +++ b/source/blender/windowmanager/intern/wm_subwindow.c @@ -108,7 +108,8 @@ void wmOrtho2(float x1, float x2, float y1, float y2) y2 += 1.0f; } - GPU_matrix_ortho_set(x1, x2, y1, y2, -100, 100); + GPU_matrix_ortho_set( + x1, x2, y1, y2, GPU_MATRIX_ORTHO_CLIP_NEAR_DEFAULT, GPU_MATRIX_ORTHO_CLIP_FAR_DEFAULT); } static void wmOrtho2_offset(const float x, const float y, const float ofs) @@ -136,6 +137,6 @@ void wmGetProjectionMatrix(float mat[4][4], const rcti *winrct) (float)width - GLA_PIXEL_OFS, -GLA_PIXEL_OFS, (float)height - GLA_PIXEL_OFS, - -100, - 100); + GPU_MATRIX_ORTHO_CLIP_NEAR_DEFAULT, + GPU_MATRIX_ORTHO_CLIP_FAR_DEFAULT); } |