Finish implement GL_ARB_texture_lod; adding the 19 additional *ARB() built-ins to the 11 non-*ARB() that were already supported.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@27542 e7fa87d3-cd2b-0410-9028-fcbf551c1848
This commit is contained in:
John Kessenich 2014-07-29 18:11:09 +00:00
parent 019a62b0ec
commit b9fc145387
4 changed files with 298 additions and 141 deletions

View File

@ -185,6 +185,10 @@ void foo2323()
v = texture3DProjLod(s3D, v, f); // ERROR
v = texture1DProjLod(s1D, v, f); // ERROR
v = shadow2DProjLod(s2DS, v, f); // ERROR
v = texture1DGradARB(s1D, f, f, f); // ERROR
v = texture2DProjGradARB(s2D, v, v2, v2); // ERROR
v = shadow2DProjGradARB(s2DS, v, v2, v2); // ERROR
}
#extension GL_ARB_shader_texture_lod : require
@ -198,9 +202,14 @@ void foo2324()
v = texture3DProjLod(s3D, v, f);
v = texture1DProjLod(s1D, v, f);
v = shadow2DProjLod(s2DS, v, f);
v = texture1DGradARB(s1D, f, f, f);
v = texture2DProjGradARB(s2D, v, v2, v2);
v = shadow2DProjGradARB(s2DS, v, v2, v2);
v = shadow2DRectProjGradARB(s2DS, v, v2, v2); // ERROR
}
uniform sampler2DRect s2DRbad;
uniform sampler2DRect s2DRbad; // ERROR
void foo121111()
{
@ -224,4 +233,6 @@ void foo12111()
v = texture2DRectProj(s2DR, v4);
v = shadow2DRect(s2DRS, v3);
v = shadow2DRectProj(s2DRS, v4);
v = shadow2DRectProjGradARB(s2DRS, v, v2, v2);
}

View File

@ -46,9 +46,13 @@ ERROR: 0:184: 'texture2DLod' : required extension not requested: GL_ARB_shader_t
ERROR: 0:185: 'texture3DProjLod' : required extension not requested: GL_ARB_shader_texture_lod
ERROR: 0:186: 'texture1DProjLod' : required extension not requested: GL_ARB_shader_texture_lod
ERROR: 0:187: 'shadow2DProjLod' : required extension not requested: GL_ARB_shader_texture_lod
WARNING: 0:190: '#extension' : extension is only partially supported: GL_ARB_shader_texture_lod
ERROR: 0:203: 'sampler2DRect' : Reserved word.
ERROR: 48 compilation errors. No code generated.
ERROR: 0:189: 'texture1DGradARB' : required extension not requested: GL_ARB_shader_texture_lod
ERROR: 0:190: 'texture2DProjGradARB' : required extension not requested: GL_ARB_shader_texture_lod
ERROR: 0:191: 'shadow2DProjGradARB' : required extension not requested: GL_ARB_shader_texture_lod
ERROR: 0:209: 'shadow2DRectProjGradARB' : no matching overloaded function found
ERROR: 0:209: 'assign' : cannot convert from 'const float' to '4-component vector of float'
ERROR: 0:212: 'sampler2DRect' : Reserved word.
ERROR: 53 compilation errors. No code generated.
Shader version: 120
@ -472,70 +476,120 @@ ERROR: node is still EOpNull!
0:187 's2DS' (uniform sampler2DShadow)
0:187 'v' (4-component vector of float)
0:187 'f' (float)
0:192 Function Definition: foo2324( (void)
0:192 Function Parameters:
0:189 move second child to first child (4-component vector of float)
0:189 'v' (4-component vector of float)
0:189 Function Call: texture1DGradARB(s11;f1;f1;f1; (4-component vector of float)
0:189 's1D' (uniform sampler1D)
0:189 'f' (float)
0:189 'f' (float)
0:189 'f' (float)
0:190 move second child to first child (4-component vector of float)
0:190 'v' (4-component vector of float)
0:190 Function Call: texture2DProjGradARB(s21;vf4;vf2;vf2; (4-component vector of float)
0:190 's2D' (uniform sampler2D)
0:190 'v' (4-component vector of float)
0:190 'v2' (2-component vector of float)
0:190 'v2' (2-component vector of float)
0:191 move second child to first child (4-component vector of float)
0:191 'v' (4-component vector of float)
0:191 Function Call: shadow2DProjGradARB(sS21;vf4;vf2;vf2; (4-component vector of float)
0:191 's2DS' (uniform sampler2DShadow)
0:191 'v' (4-component vector of float)
0:191 'v2' (2-component vector of float)
0:191 'v2' (2-component vector of float)
0:196 Function Definition: foo2324( (void)
0:196 Function Parameters:
0:? Sequence
0:197 move second child to first child (4-component vector of float)
0:197 'v' (4-component vector of float)
0:197 Function Call: texture2DLod(s21;vf2;f1; (4-component vector of float)
0:197 's2D' (uniform sampler2D)
0:197 'v2' (2-component vector of float)
0:197 'f' (float)
0:198 move second child to first child (4-component vector of float)
0:198 'v' (4-component vector of float)
0:198 Function Call: texture3DProjLod(s31;vf4;f1; (4-component vector of float)
0:198 's3D' (uniform sampler3D)
0:198 'v' (4-component vector of float)
0:198 'f' (float)
0:199 move second child to first child (4-component vector of float)
0:199 'v' (4-component vector of float)
0:199 Function Call: texture1DProjLod(s11;vf4;f1; (4-component vector of float)
0:199 's1D' (uniform sampler1D)
0:199 'v' (4-component vector of float)
0:199 'f' (float)
0:200 move second child to first child (4-component vector of float)
0:200 'v' (4-component vector of float)
0:200 Function Call: shadow2DProjLod(sS21;vf4;f1; (4-component vector of float)
0:200 's2DS' (uniform sampler2DShadow)
0:200 'v' (4-component vector of float)
0:200 'f' (float)
0:205 Function Definition: foo121111( (void)
0:205 Function Parameters:
0:? Sequence
0:208 Sequence
0:208 move second child to first child (4-component vector of float)
0:201 move second child to first child (4-component vector of float)
0:201 'v' (4-component vector of float)
0:201 Function Call: texture2DLod(s21;vf2;f1; (4-component vector of float)
0:201 's2D' (uniform sampler2D)
0:201 'v2' (2-component vector of float)
0:201 'f' (float)
0:202 move second child to first child (4-component vector of float)
0:202 'v' (4-component vector of float)
0:202 Function Call: texture3DProjLod(s31;vf4;f1; (4-component vector of float)
0:202 's3D' (uniform sampler3D)
0:202 'v' (4-component vector of float)
0:202 'f' (float)
0:203 move second child to first child (4-component vector of float)
0:203 'v' (4-component vector of float)
0:203 Function Call: texture1DProjLod(s11;vf4;f1; (4-component vector of float)
0:203 's1D' (uniform sampler1D)
0:203 'v' (4-component vector of float)
0:203 'f' (float)
0:204 move second child to first child (4-component vector of float)
0:204 'v' (4-component vector of float)
0:204 Function Call: shadow2DProjLod(sS21;vf4;f1; (4-component vector of float)
0:204 's2DS' (uniform sampler2DShadow)
0:204 'v' (4-component vector of float)
0:204 'f' (float)
0:206 move second child to first child (4-component vector of float)
0:206 'v' (4-component vector of float)
0:206 Function Call: texture1DGradARB(s11;f1;f1;f1; (4-component vector of float)
0:206 's1D' (uniform sampler1D)
0:206 'f' (float)
0:206 'f' (float)
0:206 'f' (float)
0:207 move second child to first child (4-component vector of float)
0:207 'v' (4-component vector of float)
0:207 Function Call: texture2DProjGradARB(s21;vf4;vf2;vf2; (4-component vector of float)
0:207 's2D' (uniform sampler2D)
0:207 'v' (4-component vector of float)
0:207 'v2' (2-component vector of float)
0:207 'v2' (2-component vector of float)
0:208 move second child to first child (4-component vector of float)
0:208 'v' (4-component vector of float)
0:208 Function Call: shadow2DProjGradARB(sS21;vf4;vf2;vf2; (4-component vector of float)
0:208 's2DS' (uniform sampler2DShadow)
0:208 'v' (4-component vector of float)
0:208 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:208 's2DRbad' (uniform sampler2DRect)
0:208 'v2' (2-component vector of float)
0:216 Function Definition: foo12111( (void)
0:216 Function Parameters:
0:208 'v2' (2-component vector of float)
0:208 'v2' (2-component vector of float)
0:209 'v' (4-component vector of float)
0:214 Function Definition: foo121111( (void)
0:214 Function Parameters:
0:? Sequence
0:222 move second child to first child (4-component vector of float)
0:222 'v' (4-component vector of float)
0:222 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:222 's2DR' (uniform sampler2DRect)
0:222 'v2' (2-component vector of float)
0:223 move second child to first child (4-component vector of float)
0:223 'v' (4-component vector of float)
0:223 Function Call: texture2DRectProj(sR21;vf3; (4-component vector of float)
0:223 's2DR' (uniform sampler2DRect)
0:223 'v3' (3-component vector of float)
0:224 move second child to first child (4-component vector of float)
0:224 'v' (4-component vector of float)
0:224 Function Call: texture2DRectProj(sR21;vf4; (4-component vector of float)
0:224 's2DR' (uniform sampler2DRect)
0:224 'v4' (4-component vector of float)
0:225 move second child to first child (4-component vector of float)
0:225 'v' (4-component vector of float)
0:225 Function Call: shadow2DRect(sSR21;vf3; (4-component vector of float)
0:225 's2DRS' (uniform sampler2DRectShadow)
0:225 'v3' (3-component vector of float)
0:226 move second child to first child (4-component vector of float)
0:226 'v' (4-component vector of float)
0:226 Function Call: shadow2DRectProj(sSR21;vf4; (4-component vector of float)
0:226 's2DRS' (uniform sampler2DRectShadow)
0:226 'v4' (4-component vector of float)
0:217 Sequence
0:217 move second child to first child (4-component vector of float)
0:217 'v' (4-component vector of float)
0:217 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:217 's2DRbad' (uniform sampler2DRect)
0:217 'v2' (2-component vector of float)
0:225 Function Definition: foo12111( (void)
0:225 Function Parameters:
0:? Sequence
0:231 move second child to first child (4-component vector of float)
0:231 'v' (4-component vector of float)
0:231 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:231 's2DR' (uniform sampler2DRect)
0:231 'v2' (2-component vector of float)
0:232 move second child to first child (4-component vector of float)
0:232 'v' (4-component vector of float)
0:232 Function Call: texture2DRectProj(sR21;vf3; (4-component vector of float)
0:232 's2DR' (uniform sampler2DRect)
0:232 'v3' (3-component vector of float)
0:233 move second child to first child (4-component vector of float)
0:233 'v' (4-component vector of float)
0:233 Function Call: texture2DRectProj(sR21;vf4; (4-component vector of float)
0:233 's2DR' (uniform sampler2DRect)
0:233 'v4' (4-component vector of float)
0:234 move second child to first child (4-component vector of float)
0:234 'v' (4-component vector of float)
0:234 Function Call: shadow2DRect(sSR21;vf3; (4-component vector of float)
0:234 's2DRS' (uniform sampler2DRectShadow)
0:234 'v3' (3-component vector of float)
0:235 move second child to first child (4-component vector of float)
0:235 'v' (4-component vector of float)
0:235 Function Call: shadow2DRectProj(sSR21;vf4; (4-component vector of float)
0:235 's2DRS' (uniform sampler2DRectShadow)
0:235 'v4' (4-component vector of float)
0:237 move second child to first child (4-component vector of float)
0:237 'v' (4-component vector of float)
0:237 Function Call: shadow2DRectProjGradARB(sSR21;vf4;vf2;vf2; (4-component vector of float)
0:237 's2DRS' (uniform sampler2DRectShadow)
0:237 'v' (4-component vector of float)
0:237 'v2' (2-component vector of float)
0:237 'v2' (2-component vector of float)
0:? Linker Objects
0:? 'lowp' (float)
0:? 'mediump' (float)
@ -993,70 +1047,120 @@ ERROR: node is still EOpNull!
0:187 's2DS' (uniform sampler2DShadow)
0:187 'v' (4-component vector of float)
0:187 'f' (float)
0:192 Function Definition: foo2324( (void)
0:192 Function Parameters:
0:189 move second child to first child (4-component vector of float)
0:189 'v' (4-component vector of float)
0:189 Function Call: texture1DGradARB(s11;f1;f1;f1; (4-component vector of float)
0:189 's1D' (uniform sampler1D)
0:189 'f' (float)
0:189 'f' (float)
0:189 'f' (float)
0:190 move second child to first child (4-component vector of float)
0:190 'v' (4-component vector of float)
0:190 Function Call: texture2DProjGradARB(s21;vf4;vf2;vf2; (4-component vector of float)
0:190 's2D' (uniform sampler2D)
0:190 'v' (4-component vector of float)
0:190 'v2' (2-component vector of float)
0:190 'v2' (2-component vector of float)
0:191 move second child to first child (4-component vector of float)
0:191 'v' (4-component vector of float)
0:191 Function Call: shadow2DProjGradARB(sS21;vf4;vf2;vf2; (4-component vector of float)
0:191 's2DS' (uniform sampler2DShadow)
0:191 'v' (4-component vector of float)
0:191 'v2' (2-component vector of float)
0:191 'v2' (2-component vector of float)
0:196 Function Definition: foo2324( (void)
0:196 Function Parameters:
0:? Sequence
0:197 move second child to first child (4-component vector of float)
0:197 'v' (4-component vector of float)
0:197 Function Call: texture2DLod(s21;vf2;f1; (4-component vector of float)
0:197 's2D' (uniform sampler2D)
0:197 'v2' (2-component vector of float)
0:197 'f' (float)
0:198 move second child to first child (4-component vector of float)
0:198 'v' (4-component vector of float)
0:198 Function Call: texture3DProjLod(s31;vf4;f1; (4-component vector of float)
0:198 's3D' (uniform sampler3D)
0:198 'v' (4-component vector of float)
0:198 'f' (float)
0:199 move second child to first child (4-component vector of float)
0:199 'v' (4-component vector of float)
0:199 Function Call: texture1DProjLod(s11;vf4;f1; (4-component vector of float)
0:199 's1D' (uniform sampler1D)
0:199 'v' (4-component vector of float)
0:199 'f' (float)
0:200 move second child to first child (4-component vector of float)
0:200 'v' (4-component vector of float)
0:200 Function Call: shadow2DProjLod(sS21;vf4;f1; (4-component vector of float)
0:200 's2DS' (uniform sampler2DShadow)
0:200 'v' (4-component vector of float)
0:200 'f' (float)
0:205 Function Definition: foo121111( (void)
0:205 Function Parameters:
0:? Sequence
0:208 Sequence
0:208 move second child to first child (4-component vector of float)
0:201 move second child to first child (4-component vector of float)
0:201 'v' (4-component vector of float)
0:201 Function Call: texture2DLod(s21;vf2;f1; (4-component vector of float)
0:201 's2D' (uniform sampler2D)
0:201 'v2' (2-component vector of float)
0:201 'f' (float)
0:202 move second child to first child (4-component vector of float)
0:202 'v' (4-component vector of float)
0:202 Function Call: texture3DProjLod(s31;vf4;f1; (4-component vector of float)
0:202 's3D' (uniform sampler3D)
0:202 'v' (4-component vector of float)
0:202 'f' (float)
0:203 move second child to first child (4-component vector of float)
0:203 'v' (4-component vector of float)
0:203 Function Call: texture1DProjLod(s11;vf4;f1; (4-component vector of float)
0:203 's1D' (uniform sampler1D)
0:203 'v' (4-component vector of float)
0:203 'f' (float)
0:204 move second child to first child (4-component vector of float)
0:204 'v' (4-component vector of float)
0:204 Function Call: shadow2DProjLod(sS21;vf4;f1; (4-component vector of float)
0:204 's2DS' (uniform sampler2DShadow)
0:204 'v' (4-component vector of float)
0:204 'f' (float)
0:206 move second child to first child (4-component vector of float)
0:206 'v' (4-component vector of float)
0:206 Function Call: texture1DGradARB(s11;f1;f1;f1; (4-component vector of float)
0:206 's1D' (uniform sampler1D)
0:206 'f' (float)
0:206 'f' (float)
0:206 'f' (float)
0:207 move second child to first child (4-component vector of float)
0:207 'v' (4-component vector of float)
0:207 Function Call: texture2DProjGradARB(s21;vf4;vf2;vf2; (4-component vector of float)
0:207 's2D' (uniform sampler2D)
0:207 'v' (4-component vector of float)
0:207 'v2' (2-component vector of float)
0:207 'v2' (2-component vector of float)
0:208 move second child to first child (4-component vector of float)
0:208 'v' (4-component vector of float)
0:208 Function Call: shadow2DProjGradARB(sS21;vf4;vf2;vf2; (4-component vector of float)
0:208 's2DS' (uniform sampler2DShadow)
0:208 'v' (4-component vector of float)
0:208 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:208 's2DRbad' (uniform sampler2DRect)
0:208 'v2' (2-component vector of float)
0:216 Function Definition: foo12111( (void)
0:216 Function Parameters:
0:208 'v2' (2-component vector of float)
0:208 'v2' (2-component vector of float)
0:209 'v' (4-component vector of float)
0:214 Function Definition: foo121111( (void)
0:214 Function Parameters:
0:? Sequence
0:222 move second child to first child (4-component vector of float)
0:222 'v' (4-component vector of float)
0:222 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:222 's2DR' (uniform sampler2DRect)
0:222 'v2' (2-component vector of float)
0:223 move second child to first child (4-component vector of float)
0:223 'v' (4-component vector of float)
0:223 Function Call: texture2DRectProj(sR21;vf3; (4-component vector of float)
0:223 's2DR' (uniform sampler2DRect)
0:223 'v3' (3-component vector of float)
0:224 move second child to first child (4-component vector of float)
0:224 'v' (4-component vector of float)
0:224 Function Call: texture2DRectProj(sR21;vf4; (4-component vector of float)
0:224 's2DR' (uniform sampler2DRect)
0:224 'v4' (4-component vector of float)
0:225 move second child to first child (4-component vector of float)
0:225 'v' (4-component vector of float)
0:225 Function Call: shadow2DRect(sSR21;vf3; (4-component vector of float)
0:225 's2DRS' (uniform sampler2DRectShadow)
0:225 'v3' (3-component vector of float)
0:226 move second child to first child (4-component vector of float)
0:226 'v' (4-component vector of float)
0:226 Function Call: shadow2DRectProj(sSR21;vf4; (4-component vector of float)
0:226 's2DRS' (uniform sampler2DRectShadow)
0:226 'v4' (4-component vector of float)
0:217 Sequence
0:217 move second child to first child (4-component vector of float)
0:217 'v' (4-component vector of float)
0:217 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:217 's2DRbad' (uniform sampler2DRect)
0:217 'v2' (2-component vector of float)
0:225 Function Definition: foo12111( (void)
0:225 Function Parameters:
0:? Sequence
0:231 move second child to first child (4-component vector of float)
0:231 'v' (4-component vector of float)
0:231 Function Call: texture2DRect(sR21;vf2; (4-component vector of float)
0:231 's2DR' (uniform sampler2DRect)
0:231 'v2' (2-component vector of float)
0:232 move second child to first child (4-component vector of float)
0:232 'v' (4-component vector of float)
0:232 Function Call: texture2DRectProj(sR21;vf3; (4-component vector of float)
0:232 's2DR' (uniform sampler2DRect)
0:232 'v3' (3-component vector of float)
0:233 move second child to first child (4-component vector of float)
0:233 'v' (4-component vector of float)
0:233 Function Call: texture2DRectProj(sR21;vf4; (4-component vector of float)
0:233 's2DR' (uniform sampler2DRect)
0:233 'v4' (4-component vector of float)
0:234 move second child to first child (4-component vector of float)
0:234 'v' (4-component vector of float)
0:234 Function Call: shadow2DRect(sSR21;vf3; (4-component vector of float)
0:234 's2DRS' (uniform sampler2DRectShadow)
0:234 'v3' (3-component vector of float)
0:235 move second child to first child (4-component vector of float)
0:235 'v' (4-component vector of float)
0:235 Function Call: shadow2DRectProj(sSR21;vf4; (4-component vector of float)
0:235 's2DRS' (uniform sampler2DRectShadow)
0:235 'v4' (4-component vector of float)
0:237 move second child to first child (4-component vector of float)
0:237 'v' (4-component vector of float)
0:237 Function Call: shadow2DRectProjGradARB(sSR21;vf4;vf2;vf2; (4-component vector of float)
0:237 's2DRS' (uniform sampler2DRectShadow)
0:237 'v' (4-component vector of float)
0:237 'v2' (2-component vector of float)
0:237 'v2' (2-component vector of float)
0:? Linker Objects
0:? 'lowp' (float)
0:? 'mediump' (float)

View File

@ -767,12 +767,12 @@ void TBuiltIns::initialize(int version, EProfile profile)
(profile == ECoreProfile && version < 420) ||
profile == ENoProfile) {
s->append(
"vec4 texture2DLod(sampler2D, vec2, float);" // ARB_shader_texture_lod
"vec4 texture2DProjLod(sampler2D, vec3, float);" // ARB_shader_texture_lod
"vec4 texture2DProjLod(sampler2D, vec4, float);" // ARB_shader_texture_lod
"vec4 texture3DLod(sampler3D, vec3, float);" // ARB_shader_texture_lod // OES_texture_3D, but caught by keyword check
"vec4 texture3DProjLod(sampler3D, vec4, float);" // ARB_shader_texture_lod // OES_texture_3D, but caught by keyword check
"vec4 textureCubeLod(samplerCube, vec3, float);" // ARB_shader_texture_lod
"vec4 texture2DLod(sampler2D, vec2, float);" // GL_ARB_shader_texture_lod
"vec4 texture2DProjLod(sampler2D, vec3, float);" // GL_ARB_shader_texture_lod
"vec4 texture2DProjLod(sampler2D, vec4, float);" // GL_ARB_shader_texture_lod
"vec4 texture3DLod(sampler3D, vec3, float);" // GL_ARB_shader_texture_lod // OES_texture_3D, but caught by keyword check
"vec4 texture3DProjLod(sampler3D, vec4, float);" // GL_ARB_shader_texture_lod // OES_texture_3D, but caught by keyword check
"vec4 textureCubeLod(samplerCube, vec3, float);" // GL_ARB_shader_texture_lod
"\n");
}
@ -780,14 +780,33 @@ void TBuiltIns::initialize(int version, EProfile profile)
(profile == ECoreProfile && version < 420) ||
profile == ENoProfile) {
s->append(
"vec4 texture1DLod(sampler1D, float, float);" // ARB_shader_texture_lod
"vec4 texture1DProjLod(sampler1D, vec2, float);" // ARB_shader_texture_lod
"vec4 texture1DProjLod(sampler1D, vec4, float);" // ARB_shader_texture_lod
"vec4 shadow1DLod(sampler1DShadow, vec3, float);" // ARB_shader_texture_lod
"vec4 shadow2DLod(sampler2DShadow, vec3, float);" // ARB_shader_texture_lod
"vec4 shadow1DProjLod(sampler1DShadow, vec4, float);" // ARB_shader_texture_lod
"vec4 shadow2DProjLod(sampler2DShadow, vec4, float);" // ARB_shader_texture_lod
"vec4 texture1DLod(sampler1D, float, float);" // GL_ARB_shader_texture_lod
"vec4 texture1DProjLod(sampler1D, vec2, float);" // GL_ARB_shader_texture_lod
"vec4 texture1DProjLod(sampler1D, vec4, float);" // GL_ARB_shader_texture_lod
"vec4 shadow1DLod(sampler1DShadow, vec3, float);" // GL_ARB_shader_texture_lod
"vec4 shadow2DLod(sampler2DShadow, vec3, float);" // GL_ARB_shader_texture_lod
"vec4 shadow1DProjLod(sampler1DShadow, vec4, float);" // GL_ARB_shader_texture_lod
"vec4 shadow2DProjLod(sampler2DShadow, vec4, float);" // GL_ARB_shader_texture_lod
"vec4 texture1DGradARB(sampler1D, float, float, float);" // GL_ARB_shader_texture_lod
"vec4 texture1DProjGradARB(sampler1D, vec2, float, float);" // GL_ARB_shader_texture_lod
"vec4 texture1DProjGradARB(sampler1D, vec4, float, float);" // GL_ARB_shader_texture_lod
"vec4 texture2DGradARB(sampler2D, vec2, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture2DProjGradARB(sampler2D, vec3, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture2DProjGradARB(sampler2D, vec4, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture3DGradARB(sampler3D, vec3, vec3, vec3);" // GL_ARB_shader_texture_lod
"vec4 texture3DProjGradARB(sampler3D, vec4, vec3, vec3);" // GL_ARB_shader_texture_lod
"vec4 textureCubeGradARB(samplerCube, vec3, vec3, vec3);" // GL_ARB_shader_texture_lod
"vec4 shadow1DGradARB(sampler1DShadow, vec3, float, float);" // GL_ARB_shader_texture_lod
"vec4 shadow1DProjGradARB( sampler1DShadow, vec4, float, float);" // GL_ARB_shader_texture_lod
"vec4 shadow2DGradARB(sampler2DShadow, vec3, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 shadow2DProjGradARB( sampler2DShadow, vec4, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture2DRectGradARB(sampler2DRect, vec2, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture2DRectProjGradARB( sampler2DRect, vec3, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 texture2DRectProjGradARB( sampler2DRect, vec4, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 shadow2DRectGradARB( sampler2DRectShadow, vec3, vec2, vec2);" // GL_ARB_shader_texture_lod
"vec4 shadow2DRectProjGradARB(sampler2DRectShadow, vec4, vec2, vec2);" // GL_ARB_shader_texture_lod
"\n");
}
@ -2173,6 +2192,29 @@ void IdentifyBuiltIns(int version, EProfile profile, EShLanguage language, TSymb
// Tag built-in variables and functions with additional qualifier and extension information
// that cannot be declared with the text strings.
//
// GL_ARB_shader_texture_lod functions usable only with the extension enabled
if (profile != EEsProfile) {
symbolTable.setFunctionExtensions("texture1DGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture1DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture1DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture3DGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture3DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("textureCubeGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow1DGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow1DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow2DGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow2DProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DRectGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DRectProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("texture2DRectProjGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow2DRectGradARB", 1, &GL_ARB_shader_texture_lod);
symbolTable.setFunctionExtensions("shadow2DRectProjGradARB", 1, &GL_ARB_shader_texture_lod);
}
switch(language) {
case EShLangVertex:
case EShLangTessControl:

View File

@ -154,7 +154,7 @@ void TParseContext::initializeExtensionBehavior()
extensionBehavior[GL_EXT_frag_depth] = EBhDisable;
extensionBehavior[GL_OES_EGL_image_external] = EBhDisable;
extensionBehavior[GL_EXT_shader_texture_lod] = EBhDisable;
extensionBehavior[GL_ARB_shader_texture_lod] = EBhDisablePartial;
extensionBehavior[GL_ARB_shader_texture_lod] = EBhDisable;
extensionBehavior[GL_ARB_texture_rectangle] = EBhDisable;
extensionBehavior[GL_3DL_array_objects] = EBhDisable;