Skip to content
Snippets Groups Projects
Commit 37d080c3 authored by John Kessenich's avatar John Kessenich
Browse files

Add missing non-square matrixCompMult built-in functions.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@24179 e7fa87d3-cd2b-0410-9028-fcbf551c1848
parent 7c8ca2d5
No related branches found
No related tags found
No related merge requests found
No preview for this file type
......@@ -123,3 +123,32 @@ void atest()
varying vec4 gl_TexCoord[6]; // okay, assigning a size
varying vec4 gl_TexCoord[5]; // ERROR, changing size
mat2x2 m22;
mat2x3 m23;
mat2x4 m24;
mat3x2 m32;
mat3x3 m33;
mat3x4 m34;
mat4x2 m42;
mat4x3 m43;
mat4x4 m44;
void foo123()
{
mat2 r2 = matrixCompMult(m22, m22);
mat3 r3 = matrixCompMult(m33, m33);
mat4 r4 = matrixCompMult(m44, m44);
mat2x3 r23 = matrixCompMult(m23, m23);
mat2x4 r24 = matrixCompMult(m24, m24);
mat3x2 r32 = matrixCompMult(m32, m32);
mat3x4 r34 = matrixCompMult(m34, m34);
mat4x2 r42 = matrixCompMult(m42, m42);
mat4x3 r43 = matrixCompMult(m43, m43);
mat3x2 rfoo1 = matrixCompMult(m23, m32); // ERROR
mat3x4 rfoo2 = matrixCompMult(m34, m44); // ERROR
}
......@@ -58,11 +58,12 @@ ERROR: 0:135: 'texture2DProjLod' : no matching overloaded function found
ERROR: 0:137: 'bitwise not' : not supported for this version or the enabled extensions
ERROR: 0:138: 'bitwise inclusive or' : not supported for this version or the enabled extensions
ERROR: 0:139: 'bitwise and' : not supported for this version or the enabled extensions
ERROR: 0:144: 'a' : redefinition
ERROR: 0:149: 'floating-point suffix' : not supported for this version or the enabled extensions
ERROR: 0:150: 'floating-point suffix' : not supported for this version or the enabled extensions
ERROR: 0:152: '' : syntax error
ERROR: 56 compilation errors. No code generated.
ERROR: 0:145: 'a' : redefinition
ERROR: 0:147: 'texture2DProjGradEXT' : required extension not requested: GL_EXT_shader_texture_lod
ERROR: 0:151: 'floating-point suffix' : not supported for this version or the enabled extensions
ERROR: 0:152: 'floating-point suffix' : not supported for this version or the enabled extensions
ERROR: 0:166: '' : syntax error
ERROR: 57 compilation errors. No code generated.
ERROR: node is still EOpNull!
......@@ -243,23 +244,55 @@ ERROR: node is still EOpNull!
0:139 bitwise and (mediump int)
0:139 'a' (mediump int)
0:139 'a' (mediump int)
0:144 Function Definition: foo203940(i1;f1;f1; (mediump int)
0:144 Function Parameters:
0:144 'a' (in mediump int)
0:144 'b' (in mediump float)
0:146 Sequence
0:146 Branch: Return with expression
0:146 'a' (in mediump int)
0:149 Sequence
0:149 move second child to first child (mediump float)
0:149 'f123' (mediump float)
0:149 Constant:
0:149 4.000000
0:150 Sequence
0:150 move second child to first child (mediump float)
0:150 'f124' (mediump float)
0:150 Constant:
0:150 50000000000.000000
0:145 Function Definition: foo203940(i1;f1;f1; (mediump int)
0:145 Function Parameters:
0:145 'a' (in mediump int)
0:145 'b' (in mediump float)
0:147 Sequence
0:147 Function Call: texture2DProjGradEXT(s21;vf3;vf2;vf2; (lowp 4-component vector of float)
0:147 's2Dg' (uniform lowp sampler2D)
0:147 Construct vec3 (3-component vector of float)
0:147 'f13' (invariant mediump float)
0:147 'uv2' (invariant uniform mediump 2-component vector of float)
0:147 'uv2' (invariant uniform mediump 2-component vector of float)
0:148 Branch: Return with expression
0:148 'a' (in mediump int)
0:151 Sequence
0:151 move second child to first child (mediump float)
0:151 'f123' (mediump float)
0:151 Constant:
0:151 4.000000
0:152 Sequence
0:152 move second child to first child (mediump float)
0:152 'f124' (mediump float)
0:152 Constant:
0:152 50000000000.000000
0:158 Function Definition: foo323433( (void)
0:158 Function Parameters:
0:160 Sequence
0:160 Function Call: texture2DLodEXT(s21;vf2;f1; (lowp 4-component vector of float)
0:160 's2Dg' (uniform lowp sampler2D)
0:160 'uv2' (invariant uniform mediump 2-component vector of float)
0:160 'f13' (invariant mediump float)
0:161 Function Call: texture2DProjGradEXT(s21;vf3;vf2;vf2; (lowp 4-component vector of float)
0:161 's2Dg' (uniform lowp sampler2D)
0:161 Construct vec3 (3-component vector of float)
0:161 'f13' (invariant mediump float)
0:161 'uv2' (invariant uniform mediump 2-component vector of float)
0:161 'uv2' (invariant uniform mediump 2-component vector of float)
0:162 Function Call: texture2DGradEXT(s21;vf2;vf2;vf2; (lowp 4-component vector of float)
0:162 's2Dg' (uniform lowp sampler2D)
0:162 'uv2' (invariant uniform mediump 2-component vector of float)
0:162 'uv2' (invariant uniform mediump 2-component vector of float)
0:162 'uv2' (invariant uniform mediump 2-component vector of float)
0:163 Function Call: textureCubeGradEXT(sC1;vf3;vf3;vf3; (lowp 4-component vector of float)
0:163 'sCube' (uniform lowp samplerCube)
0:163 Construct vec3 (3-component vector of float)
0:163 'f13' (invariant mediump float)
0:163 Construct vec3 (3-component vector of float)
0:163 'f13' (invariant mediump float)
0:163 Construct vec3 (3-component vector of float)
0:163 'f13' (invariant mediump float)
0:? Linker Objects
0:? 'a' (3-element array of mediump int)
0:? 'uint' (mediump int)
......@@ -279,8 +312,10 @@ ERROR: node is still EOpNull!
0:? 'sExt' (uniform lowp samplerExternalOES)
0:? 'mediumExt' (uniform mediump samplerExternalOES)
0:? 'highExt' (uniform highp samplerExternalOES)
0:? 's2Dg' (uniform lowp sampler2D)
0:? 'f123' (mediump float)
0:? 'f124' (mediump float)
0:? 'sCube' (uniform lowp samplerCube)
Linked fragment stage:
......
......@@ -30,7 +30,11 @@ ERROR: 0:97: 'out' : overloaded functions must have the same parameter qualifier
ERROR: 0:99: 'return' : function return is not matching type:
ERROR: 0:115: 'return' : void function cannot return a value
ERROR: 0:125: 'gl_TexCoord' : redeclaration of array with size
ERROR: 31 compilation errors. No code generated.
ERROR: 0:152: 'matrixCompMult' : no matching overloaded function found
ERROR: 0:152: '=' : cannot convert from 'const float' to '3X2 matrix of float'
ERROR: 0:153: 'matrixCompMult' : no matching overloaded function found
ERROR: 0:153: '=' : cannot convert from 'const float' to '3X4 matrix of float'
ERROR: 35 compilation errors. No code generated.
ERROR: node is still EOpNull!
......@@ -304,6 +308,63 @@ ERROR: node is still EOpNull!
0:121 'gl_TexCoord' (smooth in 6-element array of 4-component vector of float)
0:121 Constant:
0:121 3 (const int)
0:139 Function Definition: foo123( (void)
0:139 Function Parameters:
0:141 Sequence
0:141 Sequence
0:141 move second child to first child (2X2 matrix of float)
0:141 'r2' (2X2 matrix of float)
0:141 component-wise multiply (2X2 matrix of float)
0:141 'm22' (2X2 matrix of float)
0:141 'm22' (2X2 matrix of float)
0:142 Sequence
0:142 move second child to first child (3X3 matrix of float)
0:142 'r3' (3X3 matrix of float)
0:142 component-wise multiply (3X3 matrix of float)
0:142 'm33' (3X3 matrix of float)
0:142 'm33' (3X3 matrix of float)
0:143 Sequence
0:143 move second child to first child (4X4 matrix of float)
0:143 'r4' (4X4 matrix of float)
0:143 component-wise multiply (4X4 matrix of float)
0:143 'm44' (4X4 matrix of float)
0:143 'm44' (4X4 matrix of float)
0:145 Sequence
0:145 move second child to first child (2X3 matrix of float)
0:145 'r23' (2X3 matrix of float)
0:145 component-wise multiply (2X3 matrix of float)
0:145 'm23' (2X3 matrix of float)
0:145 'm23' (2X3 matrix of float)
0:146 Sequence
0:146 move second child to first child (2X4 matrix of float)
0:146 'r24' (2X4 matrix of float)
0:146 component-wise multiply (2X4 matrix of float)
0:146 'm24' (2X4 matrix of float)
0:146 'm24' (2X4 matrix of float)
0:147 Sequence
0:147 move second child to first child (3X2 matrix of float)
0:147 'r32' (3X2 matrix of float)
0:147 component-wise multiply (3X2 matrix of float)
0:147 'm32' (3X2 matrix of float)
0:147 'm32' (3X2 matrix of float)
0:148 Sequence
0:148 move second child to first child (3X4 matrix of float)
0:148 'r34' (3X4 matrix of float)
0:148 component-wise multiply (3X4 matrix of float)
0:148 'm34' (3X4 matrix of float)
0:148 'm34' (3X4 matrix of float)
0:149 Sequence
0:149 move second child to first child (4X2 matrix of float)
0:149 'r42' (4X2 matrix of float)
0:149 component-wise multiply (4X2 matrix of float)
0:149 'm42' (4X2 matrix of float)
0:149 'm42' (4X2 matrix of float)
0:150 Sequence
0:150 move second child to first child (4X3 matrix of float)
0:150 'r43' (4X3 matrix of float)
0:150 component-wise multiply (4X3 matrix of float)
0:150 'm43' (4X3 matrix of float)
0:150 'm43' (4X3 matrix of float)
0:? Linker Objects
0:? 'lowp' (float)
0:? 'mediump' (float)
......@@ -318,6 +379,15 @@ ERROR: node is still EOpNull!
0:? 'uimage2DRect' (float)
0:? 'a' (int)
0:? 'gl_TexCoord' (smooth in 6-element array of 4-component vector of float)
0:? 'm22' (2X2 matrix of float)
0:? 'm23' (2X3 matrix of float)
0:? 'm24' (2X4 matrix of float)
0:? 'm32' (3X2 matrix of float)
0:? 'm33' (3X3 matrix of float)
0:? 'm34' (3X4 matrix of float)
0:? 'm42' (4X2 matrix of float)
0:? 'm43' (4X3 matrix of float)
0:? 'm44' (4X4 matrix of float)
Linked fragment stage:
......
......@@ -527,6 +527,13 @@ void TBuiltIns::initialize(int version, EProfile profile)
"mat4x2 transpose(mat2x4 m);"
"mat3x4 transpose(mat4x3 m);"
"mat4x3 transpose(mat3x4 m);"
"mat2x3 matrixCompMult(mat2x3, mat2x3);"
"mat2x4 matrixCompMult(mat2x4, mat2x4);"
"mat3x2 matrixCompMult(mat3x2, mat3x2);"
"mat3x4 matrixCompMult(mat3x4, mat3x4);"
"mat4x2 matrixCompMult(mat4x2, mat4x2);"
"mat4x3 matrixCompMult(mat4x3, mat4x3);"
"\n");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment