Closed neuralsandwich closed 11 years ago
You can't multiply a mat4 by a vec3. To get around this you could multiply it by a vec4 instead. do something like
vertex_position = (model * vec4(position,1)).xyz;
I was thinking that in the workbook by Kevin Chalmers it said to do it. I am still getting used to GLM and OpenGL so I wasn't sure.
I'll try it and see what happens!
Issue with line 20 (commit 5676c216c1f6f3d9da8042d0517cc4b9d6e5d4b4) of phong.vert, which stops the shader from linking.
The overall lighting effect doesn't seem like it is correct either.
This doesn't work
This works