diff options
author | Harley Acheson <harley.acheson@gmail.com> | 2019-08-27 18:04:06 +0300 |
---|---|---|
committer | Harley Acheson <harley.acheson@gmail.com> | 2019-08-27 18:05:17 +0300 |
commit | a758dce0fa784cb1d8027101784f8c6280512bad (patch) | |
tree | 8375edb7e7365bd59b578405bfab3e478c51589c /source/blender/editors/space_graph/graph_draw.c | |
parent | ce47dc5e70d594e580d05dbdc7f297d2bd63b814 (diff) |
UI: Graph Editor Dot Scaling
Scale Graph Editor keyframe dots and handles based on Resolution Scale rather than Line Width.
Differential Revision: https://developer.blender.org/D5600
Reviewed by Brecht Van Lommel
Diffstat (limited to 'source/blender/editors/space_graph/graph_draw.c')
-rw-r--r-- | source/blender/editors/space_graph/graph_draw.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c index e7ba498fc11..e18a440f7c0 100644 --- a/source/blender/editors/space_graph/graph_draw.c +++ b/source/blender/editors/space_graph/graph_draw.c @@ -205,7 +205,7 @@ static void draw_fcurve_keyframe_vertices(FCurve *fcu, View2D *v2d, bool edit, u { immBindBuiltinProgram(GPU_SHADER_2D_POINT_UNIFORM_SIZE_UNIFORM_COLOR_AA); - immUniform1f("size", UI_GetThemeValuef(TH_VERTEX_SIZE) * U.pixelsize); + immUniform1f("size", UI_GetThemeValuef(TH_VERTEX_SIZE) * U.dpi_fac); draw_fcurve_selected_keyframe_vertices(fcu, v2d, edit, false, pos); draw_fcurve_selected_keyframe_vertices(fcu, v2d, edit, true, pos); @@ -269,8 +269,8 @@ static void draw_fcurve_handle_vertices(FCurve *fcu, immBindBuiltinProgram(GPU_SHADER_2D_POINT_UNIFORM_SIZE_UNIFORM_COLOR_OUTLINE_AA); /* set handle size */ - immUniform1f("size", (1.4f * UI_GetThemeValuef(TH_HANDLE_VERTEX_SIZE)) * U.pixelsize); - immUniform1f("outlineWidth", 1.5f * U.pixelsize); + immUniform1f("size", (1.4f * UI_GetThemeValuef(TH_HANDLE_VERTEX_SIZE)) * U.dpi_fac); + immUniform1f("outlineWidth", 1.5f * U.dpi_fac); draw_fcurve_selected_handle_vertices(fcu, v2d, false, sel_handle_only, pos); draw_fcurve_selected_handle_vertices(fcu, v2d, true, sel_handle_only, pos); |