OpenGL2: Support GL_ARB_vertex_type_2_10_10_10_rev for normals/tangents/lightdirs
This commit is contained in:
parent
4c9d39ae6e
commit
f6f3a19f73
13 changed files with 239 additions and 198 deletions
|
@ -206,7 +206,7 @@ void main()
|
|||
#if defined(USE_LIGHT_VECTOR)
|
||||
vec3 L = u_LightOrigin.xyz - (position * u_LightOrigin.w);
|
||||
#elif defined(USE_LIGHT)
|
||||
vec3 L = attr_LightDirection;
|
||||
vec3 L = attr_LightDirection * 2.0 - vec3(1.0);
|
||||
#if defined(USE_MODELMATRIX)
|
||||
L = (u_ModelMatrix * vec4(L, 0.0)).xyz;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue