Blender Git Commit Log

Git Commits -> Revision 8dcf7a4

Revision 8dcf7a4 by Mike Erwin (master)
April 16, 2017, 19:04 (GMT)
OpenGL: fix GPU_SHADER_SIMPLE_LIGHTING_SMOOTH_COLOR

The fragment shader expects a normal, but the vertex shader was not providing one.

Fix: added a new vertex shader that has normals + smooth color interpolation.

I also split gpu_shader_3D_vert in two:
- one with just position
- one with position + normal

For each of the builtin shaders, we should be able to look at the GLSL and tell exactly what it's doing. Using #defines and #ifdefs for rendering options makes the shaders hard to read and easy to break.

Commit Details:

Full Hash: 8dcf7a46a28dd291680873f78a8a5259d065ee2f
Parent Commit: 6a2c823
Lines Changed: +51, -17

2 Added Paths:

/source/blender/gpu/shaders/gpu_shader_3D_normal_smooth_color_vert.glsl (+26, -0) (View)
/source/blender/gpu/shaders/gpu_shader_3D_normal_vert.glsl (+19, -0) (View)

3 Modified Paths:

/source/blender/gpu/CMakeLists.txt (+2, -0) (Diff)
/source/blender/gpu/intern/gpu_shader.c (+4, -3) (Diff)
/source/blender/gpu/shaders/gpu_shader_3D_vert.glsl (+0, -14) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021