Commit b94954a7 authored by Marek Olšák's avatar Marek Olšák

glsl-1.40/1.50: basic compiler tests for the compatibility profile

Acked-by: Timothy Arceri's avatarTimothy Arceri <tarceri@itsqueeze.com>
parent c941213f
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void main()
{
ftransform();
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void func()
{
gl_BackColor = vec4(0.0);
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackLightModelProduct.sceneColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackLightProduct[0].ambient;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackMaterial.emission;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void func()
{
gl_BackSecondaryColor = vec4(0.0);
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_ClipPlane[0];
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void func()
{
gl_ClipVertex = vec4(0.0);
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_Color;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_Color;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_EyePlaneS[0];
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_Fog.color;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
float func()
{
return gl_FogCoord;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
float func()
{
return gl_FogFragCoord;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_FogParameters var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void func()
{
gl_FrontColor = vec4(0.0);
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_FrontLightModelProduct.sceneColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_FrontLightProduct[0].ambient;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_FrontMaterial.emission;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
void func()
{
gl_FrontSecondaryColor = vec4(0.0);
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_LightModelParameters var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_LightModelProducts var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_LightProducts var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_LightSource[0].ambient;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_LightSourceParameters var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_MaterialParameters var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
int func()
{
return gl_MaxClipPlanes;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
int func()
{
return gl_MaxLights;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
int func()
{
return gl_MaxTextureCoords;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
int func()
{
return gl_MaxTextureUnits;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
mat4 func()
{
return gl_ModelViewMatrix;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_MultiTexCoord0;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec3 func()
{
return gl_Normal;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
mat3 func()
{
return gl_NormalMatrix;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_ObjectPlaneS[0];
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
float func()
{
return gl_Point.size;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
uniform gl_PointParameters var;
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_SecondaryColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_SecondaryColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_TextureEnvColor[0];
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
mat4 func()
{
return gl_TextureMatrix[0];
}
// [config]
// expect_result: pass
// glsl_version: 1.40compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 140
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_Vertex;
}
// [config]
// expect_result: fail
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
void main()
{
ftransform();
}
// [config]
// expect_result: pass
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
void func()
{
gl_BackColor = gl_in[0].gl_BackColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackLightModelProduct.sceneColor;
}
// [config]
// expect_result: pass
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackLightProduct[0].ambient;
}
// [config]
// expect_result: pass
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
vec4 func()
{
return gl_BackMaterial.emission;
}
// [config]
// expect_result: pass
// glsl_version: 1.50compatibility
// require_extensions: GL_ARB_compatibility
// [end config]
#version 150
#extension GL_ARB_compatibility : enable
void func()
{
gl_BackSecondaryColor = gl_in[