Construct non matrices from matrix in GLSL
Construct non matrices from matrix in GLSL

GLSL supports constructing vectors from matrices. In the case
of vec3(mat2), vec4(mat2) or vec4(mat3), a second instruction
is required to copy the remaining matrix elements from the
2nd row of the matrix into the rest of the vector.

Fixes 6 webgl conformance tests:
conformance/glsl/constructors/glsl-construct-vec3.html
conformance/glsl/constructors/glsl-construct-vec4.html
conformance/glsl/constructors/glsl-construct-ivec3.html
conformance/glsl/constructors/glsl-construct-ivec4.html
conformance/glsl/constructors/glsl-construct-bvec3.html
conformance/glsl/constructors/glsl-construct-bvec4.html

Change-Id: I85ffd3b60623d0dce2bd7c0027748e1829a27dbc
Reviewed-on: https://swiftshader-review.googlesource.com/16469
Tested-by: Alexis Hétu <1c7141772178a7e80858c3db5052b328076f08f4@google.com>
Reviewed-by: Nicolas Capens <51edc787c30f24c4904e8ffbb5523c3a9f7a451d@google.com>
Reviewed-by: Alexis Hétu <1c7141772178a7e80858c3db5052b328076f08f4@google.com>

google/swiftshader,bkaradzic/SwiftShader,bkaradzic/SwiftShader,bkaradzic/SwiftShader,google/swiftshader,bkaradzic/SwiftShader,google/swiftshader,bkaradzic/SwiftShader