[Bf-blender-cvs] [3579350] blender2.8: immediate mode: small cleanup on timeline

Dalai Felinto noreply at git.blender.org
Thu Oct 13 16:23:35 CEST 2016


Commit: 35793504815a1cd0eb38df54d9ae99cc441b4f2f
Author: Dalai Felinto
Date:   Thu Oct 13 14:17:52 2016 +0000
Branches: blender2.8
https://developer.blender.org/rB35793504815a1cd0eb38df54d9ae99cc441b4f2f

immediate mode: small cleanup on timeline

(no need to unbind/rebind the same program)

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

M	source/blender/editors/space_time/space_time.c

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

diff --git a/source/blender/editors/space_time/space_time.c b/source/blender/editors/space_time/space_time.c
index 8b54d26..f199820 100644
--- a/source/blender/editors/space_time/space_time.c
+++ b/source/blender/editors/space_time/space_time.c
@@ -96,12 +96,9 @@ static void time_draw_sfra_efra(Scene *scene, View2D *v2d)
 		immRectf(pos, v2d->cur.xmin, v2d->cur.ymin, v2d->cur.xmax, v2d->cur.ymax);
 	}
 
-	immUnbindProgram();
-
 	glDisable(GL_BLEND);
 
 	/* thin lines where the actual frames are */
-	immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
 	immUniformThemeColorShade(TH_BACK, -60);
 
 	immBegin(GL_LINES, 4);
@@ -220,7 +217,7 @@ static void time_draw_idblock_keyframes(View2D *v2d, ID *id, short onlysel, cons
 		immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
 		immUniformColor3ubv(color);
 
-		immBeginAtMost(GL_LINES, max_len * 2.0f);
+		immBeginAtMost(GL_LINES, max_len * 2);
 
 		for (; (ak) && (ak->cfra <= v2d->cur.xmax);
 			ak = ak->next)




More information about the Bf-blender-cvs mailing list