From 6864066ecdf3291d2a443ab05bd2e793a38af683 Mon Sep 17 00:00:00 2001 From: Matt Turner Date: Tue, 11 Dec 2012 12:10:58 -0800 Subject: Transform the vertex by each of the bones that influence it --- data/simple.vert | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'data/simple.vert') diff --git a/data/simple.vert b/data/simple.vert index 7d771c4..d9cebc2 100644 --- a/data/simple.vert +++ b/data/simple.vert @@ -21,13 +21,12 @@ varying vec4 color; void main(void) { - /* FINISHME: Transform the vertex by each of the bones that influence - * FINISHME: it. - */ - vec4 p_ws = m[0] * position; + vec4 px_ws = m[int(weight.x)] * position; + vec4 py_ws = m[int(weight.y)] * position; /* FINISME: Blend the transformed locations. */ + vec4 p_ws = px_ws; /* Transform the final world-space position to camera-space and -- cgit v1.2.3