KalebDark / angleproject

Automatically exported from code.google.com/p/angleproject
Other
0 stars 0 forks source link

Add support for arrays as return values in output #971

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Run the WebGL 2 conformance test 
https://www.khronos.org/registry/webgl/sdk/tests/deqp/data/gles3/shaders/arrays.
html

What is the expected output? What do you see instead?
Expected: tests related to arrays as return values pass.
Actual: tests related to arrays as return values fail.

This is simple to fix for GLSL output, it just needs to write the array type 
correctly. HLSL output needs to be written so that the array is an out 
parameter instead of a return value.

Original issue reported on code.google.com by oetu...@nvidia.com on 13 Apr 2015 at 9:40

GoogleCodeExporter commented 9 years ago
Project: angle/angle
Branch : master
Author : Olli Etuaho <oetuaho@nvidia.com>
Commit : ab6fc6a2150963795e405a8faac1137cf7426d5d

Code-Review  0 : Nicolas Capens, Olli Etuaho
Code-Review  +1: Jamie Madill
Code-Review  +2: Geoff Lang
Verified     0 : Geoff Lang, Jamie Madill, Nicolas Capens
Verified     +1: Olli Etuaho
Commit Queue   : Chumped
Change-Id      : I63aa8c54d2696f65351b23acb0749a487298ddfb
Reviewed-at    : https://chromium-review.googlesource.com/265410

Add support for arrays as function return values in GLSL output

Output the array brackets and the array size correctly when a function's
return value type is array.

Tested with WebGL 2 test sdk/tests/deqp/data/gles3/shaders/arrays.html

BUG=angleproject:971
TEST=WebGL 2 conformance tests

src/compiler/translator/OutputGLSLBase.cpp

Original comment by bugdro...@chromium.org on 15 Apr 2015 at 7:32