parent
6484274048
commit
71835808d3
|
@ -21,7 +21,7 @@ void main()
|
|||
|
||||
init_globals();
|
||||
/* View position is passed to keep accuracy. */
|
||||
g_data.N = normal_view_to_world(drw_view_incident_vector(interp.P));
|
||||
g_data.N = drw_normal_view_to_world(drw_view_incident_vector(interp.P));
|
||||
g_data.Ng = g_data.N;
|
||||
g_data.P = -g_data.N;
|
||||
attrib_load();
|
||||
|
|
|
@ -57,7 +57,7 @@ vec3 drw_world_incident_vector(vec3 P)
|
|||
*/
|
||||
vec3 drw_view_incident_vector(vec3 vP)
|
||||
{
|
||||
return drw_view_is_perspective() ? normalize(vP) : vec3(0.0, 0.0, -1.0);
|
||||
return drw_view_is_perspective() ? normalize(-vP) : vec3(0.0, 0.0, 1.0);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue