Commit 8c427fb1 authored by Pierre Kraemer's avatar Pierre Kraemer

update shader version declaration for GL3

parent 8d464248
// ShaderRadiancePerVertex::vertexShaderText
#extension GL_EXT_gpu_shader4 : enable // need GLSL v1.30 -> if not available, use a uniform for passing textureSize instead of calling textureSize2D
//#extension GL_EXT_gpu_shader4 : enable // need GLSL v1.30 -> if not available, use a uniform for passing textureSize instead of calling textureSize2D
ATTRIBUTE vec3 VertexPosition;
ATTRIBUTE vec3 VertexNormal;
......@@ -69,7 +69,7 @@ void set_eval_direction (vec3 v)
void main ()
{
int size = (textureSize2D(texture,0)).x; // supposed square matrix
int size = (textureSize(texture,0)).x; // supposed square matrix
//init_K_tab();
vec3 eyeV = normalize(camera - VertexPosition); // normalized outgoing line-of-sight vector
......
// ShaderRadiancePerVertex::fragmentShaderInterpText
#extension GL_EXT_gpu_shader4 : enable // need GLSL v1.30 -> if not available, use a uniform for passing textureSize instead of calling textureSize2D
//#extension GL_EXT_gpu_shader4 : enable // need GLSL v1.30 -> if not available, use a uniform for passing textureSize instead of calling textureSize2D
PRECISION;
......@@ -75,7 +75,7 @@ void set_eval_direction (vec3 v)
void main (void)
{
int size = (textureSize2D(texture,0)).x; // supposed square matrix
int size = (textureSize(texture,0)).x; // supposed square matrix
vec3 eyeV = normalize(camera - vxPos); // normalized outgoing line-of-sight vector
eyeV = 2*dot(vxNorm,eyeV)*vxNorm-eyeV ; // symmetrize
......
......@@ -65,7 +65,7 @@ std::string GLSLShader::DEFINES_GL2=\
std::string GLSLShader::DEFINES_GL3=\
"#version 150\n"
"#version 330\n"
"#define PRECISION precision highp float\n"
"#define ATTRIBUTE in\n"
"#define VARYING_VERT out\n"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment