ATI compatibility pass

master
Dave Parks 2010-10-06 12:53:26 -05:00
parent 478e0927c8
commit 21b1b91c44
174 changed files with 369 additions and 16 deletions

View File

@ -704,6 +704,7 @@ void LLGLSLShader::uniformMatrix4fv(U32 index, U32 count, GLboolean transpose, c
GLint LLGLSLShader::getUniformLocation(const string& uniform)
{
GLint ret = -1;
if (mProgramObject > 0)
{
std::map<string, GLint>::iterator iter = mUniformMap.find(uniform);
@ -718,11 +719,19 @@ GLint LLGLSLShader::getUniformLocation(const string& uniform)
}
stop_glerror();
}
return iter->second;
ret = iter->second;
}
}
return -1;
if (gDebugGL)
{
if (ret == -1 && ret != glGetUniformLocationARB(mProgramObject, uniform.c_str()))
{
llerrs << "Uniform map invalid." << llendl;
}
}
return ret;
}
GLint LLGLSLShader::getAttribLocation(U32 attrib)

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void default_lighting();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
attribute vec4 weight; //1

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);
mat4 getSkinnedTransform();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void default_lighting();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLightingSpecular(vec3 pos, vec3 norm, vec4 color, inout vec4 specularColor, vec4 baseCol);
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
mat4 getSkinnedTransform();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* Copyright (c) 2007-$CurrentYear$, Linden Research, Inc.
* $License$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);
mat4 getObjectSkinnedTransform();
@ -22,6 +24,9 @@ varying vec3 vary_ambient;
varying vec3 vary_directional;
varying vec3 vary_normal;
varying vec3 vary_light;
varying vec3 vary_fragcoord;
uniform float near_clip;
void main()
{
@ -38,7 +43,8 @@ void main()
norm = gl_Vertex.xyz + gl_Normal.xyz;
norm = normalize(( trans*vec4(norm, 1.0) ).xyz-pos.xyz);
gl_Position = gl_ProjectionMatrix * pos;
vec4 frag_pos = gl_ProjectionMatrix * pos;
gl_Position = frag_pos;
vary_position = pos.xyz;
vary_normal = norm;
@ -70,6 +76,8 @@ void main()
gl_FrontColor = col;
gl_FogFragCoord = pos.z;
vary_fragcoord.xyz = frag_pos.xyz + vec3(0,0,near_clip);
}

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);
void calcAtmospherics(vec3 inPositionEye);

View File

@ -5,6 +5,8 @@
* $License$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;
uniform sampler2DShadow shadowMap0;
uniform sampler2DShadow shadowMap1;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);
mat4 getSkinnedTransform();
@ -21,6 +23,9 @@ varying vec3 vary_position;
varying vec3 vary_ambient;
varying vec3 vary_directional;
varying vec3 vary_normal;
varying vec3 vary_fragcoord;
uniform float near_clip;
void main()
{
@ -40,7 +45,9 @@ void main()
norm.z = dot(trans[2].xyz, gl_Normal);
norm = normalize(norm);
gl_Position = gl_ProjectionMatrix * pos;
vec4 frag_pos = gl_ProjectionMatrix * pos;
gl_Position = frag_pos;
vary_position = pos.xyz;
vary_normal = norm;
@ -71,7 +78,8 @@ void main()
gl_FrontColor = col;
gl_FogFragCoord = pos.z;
vary_fragcoord.xyz = frag_pos.xyz + vec3(0,0,near_clip);
}

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
mat4 getSkinnedTransform();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
mat4 getSkinnedTransform();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec2 vary_fragcoord;
uniform vec2 screen_res;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;
uniform sampler2D bumpMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_mat0;
varying vec3 vary_mat1;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_normal;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec2 vary_fragcoord;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;
uniform sampler2D normalMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void main()
{

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
uniform sampler2DRect diffuseMap;
varying vec2 vary_fragcoord;

View File

@ -5,6 +5,9 @@
* $/LicenseInfo$
*/
#version 120
varying vec2 vary_fragcoord;
uniform vec2 screen_res;

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable
uniform sampler2DRect depthMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
varying vec4 vary_light;
varying vec4 vary_fragcoord;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec2 vary_fragcoord;
uniform vec2 screen_res;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2DRect depthMap;
uniform sampler2DRect normalMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec2 vary_fragcoord;
uniform vec2 screen_res;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec4 post_pos;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform vec2 screen_res;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
//class 1, no shadow, no SSAO, should never be called

View File

@ -4,6 +4,8 @@
* Copyright (c) 2007-$CurrentYear$, Linden Research, Inc.
* $License$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec4 vary_light;
varying vec2 vary_fragcoord;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D detail_0;
uniform sampler2D detail_1;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_normal;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_normal;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
#extension GL_ARB_texture_rectangle : enable

View File

@ -5,6 +5,7 @@
* $/LicenseInfo$
*/
#version 120
void main()
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;
uniform float glowStrength;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform vec2 glowDelta;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D detail0;
uniform sampler2D detail1;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
// this class1 shader is just a copy of terrainF

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;
uniform sampler2D bumpMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec3 scaleSoftClip(vec3 inColor);
vec3 atmosTransport(vec3 inColor);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 applyWaterFog(vec4 color)
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void main()
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -5,6 +5,8 @@
* $License$
*/
#version 120
uniform sampler2D diffuseMap;
uniform samplerCube environmentMap;

View File

@ -5,6 +5,8 @@
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLight(vec3 n, vec3 l)
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLight(vec3 n, vec3 l)

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLight(vec3 n, vec3 l);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLight(vec3 n, vec3 l);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform sampler2D diffuseMap;

View File

@ -4,6 +4,9 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLightSpecular(inout vec4 specular, vec3 view, vec3 n, vec3 l, vec3 lightCol, float da);
vec3 atmosAmbient(vec3 light);
vec3 atmosAffectDirectionalLight(float lightIntensity);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
float calcDirectionalLight(vec3 n, vec3 l);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void fullbright_lighting();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void fullbright_shiny_lighting();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* Copyright (c) 2007-$CurrentYear$, Linden Research, Inc.
* $License$
*/
#version 120
void fullbright_shiny_lighting_water();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void fullbright_lighting_water();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void shiny_lighting();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void shiny_lighting_water();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void default_lighting();

View File

@ -1,5 +1,5 @@
/**
* @file simpleV.glsl
* @file simpleSkinnedV.glsl
*
* Copyright (c) 2007-$CurrentYear$, Linden Research, Inc.
* $License$

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLighting(vec3 pos, vec3 norm, vec4 color, vec4 baseCol);
void calcAtmospherics(vec3 inPositionEye);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void default_lighting_water();

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec3 atmosLighting(vec3 light)
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec3 atmosAmbient(vec3 light)
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
void setPositionEye(vec3 v);

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_PositionEye;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
varying vec3 vary_PositionEye;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
uniform vec4 gamma;

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2005&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec3 atmosTransport(vec3 light)
{

View File

@ -4,6 +4,8 @@
* $LicenseInfo:firstyear=2007&license=viewerlgpl$
* $/LicenseInfo$
*/
#version 120
vec4 calcLightingSpecular(vec3 pos, vec3 norm, vec4 color, inout vec4 specularColor, vec4 baseCol);
void calcAtmospherics(vec3 inPositionEye);

Some files were not shown because too many files have changed in this diff Show More