[ui] Viewer3D: introduce SphericalHarmonics shader + display mode

Add experimental render mode to display model normals or shading based on spherical harmonics coefficients
This commit is contained in:
Yann Lanthony 2019-02-08 16:31:16 +01:00 committed by Fabien Castan
parent 9aa059a565
commit 3ae95869bd
7 changed files with 194 additions and 1 deletions

View file

@ -0,0 +1,16 @@
#version 330 core
in vec3 vertexPosition;
in vec3 vertexNormal;
out vec3 normal;
uniform mat4 modelView;
uniform mat3 modelViewNormal;
uniform mat4 mvp;
void main()
{
normal = vertexNormal;
gl_Position = mvp * vec4( vertexPosition, 1.0 );
}