diff --git a/source/blender/editors/transform/transform_constraints.c b/source/blender/editors/transform/transform_constraints.c index 9b92a37abdf..25034e0bb08 100644 --- a/source/blender/editors/transform/transform_constraints.c +++ b/source/blender/editors/transform/transform_constraints.c @@ -778,7 +778,14 @@ static void drawLine( uint pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 3, GPU_FETCH_FLOAT); - immBindBuiltinProgram(GPU_SHADER_3D_UNIFORM_COLOR); + float viewport[4]; + GPU_viewport_size_get_f(viewport); + GPU_blend(GPU_BLEND_ALPHA); + + immBindBuiltinProgram(GPU_SHADER_3D_POLYLINE_UNIFORM_COLOR); + immUniform2fv("viewportSize", &viewport[2]); + immUniform1f("lineWidth", U.pixelsize * 2.0f); + immUniformColor3ubv(col2); immBegin(GPU_PRIM_LINES, 2);