From af61b5eb0c1bef93e8df1434b174944e2b40445d Mon Sep 17 00:00:00 2001 From: Mike Erwin Date: Sun, 16 Apr 2017 13:44:34 -0400 Subject: cleanup use of immUniformColor - use best function for the job - don't specify alpha if 100% - 'f' for floating point literals --- source/blender/editors/space_graph/graph_draw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/editors/space_graph/graph_draw.c') diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c index 37ce5d8075b..a732cc77aa9 100644 --- a/source/blender/editors/space_graph/graph_draw.c +++ b/source/blender/editors/space_graph/graph_draw.c @@ -952,7 +952,7 @@ void graph_draw_ghost_curves(bAnimContext *ac, SpaceIpo *sipo, ARegion *ar) * - this is set by the function which creates these * - draw with a fixed opacity of 2 */ - immUniformColor4f(fcu->color[0], fcu->color[1], fcu->color[2], 0.5f); + immUniformColor3fvAlpha(fcu->color, 0.5f); /* simply draw the stored samples */ draw_fcurve_curve_samples(ac, NULL, fcu, &ar->v2d, pos); @@ -1036,7 +1036,7 @@ void graph_draw_curves(bAnimContext *ac, SpaceIpo *sipo, ARegion *ar, View2DGrid /* set whatever color the curve has set * - unselected curves draw less opaque to help distinguish the selected ones */ - immUniformColor4f(fcu->color[0], fcu->color[1], fcu->color[2], fcurve_display_alpha(fcu)); + immUniformColor3fvAlpha(fcu->color, fcurve_display_alpha(fcu)); } /* draw F-Curve */ -- cgit v1.2.3