glslang/hlsl
steve-lunarg 26d3145334 HLSL default function parameters
This PR adds support for default function parameters in the following cases:

1. Simple constants, such as void fn(int x, float myparam = 3)
2. Expressions that can be const folded, such a ... myparam = sin(some_const)
3. Initializer lists that can be const folded, such as ... float2 myparam = {1,2}

New tests are added: hlsl.params.default.frag and hlsl.params.default.err.frag
(for testing error situations, such as ambiguity or non-const-foldable).

In order to avoid sampler method ambiguity, the hlsl better() lambda now
considers sampler matches.  Previously, all sampler types looked identical
since only the basic type of EbtSampler was considered.
2016-12-29 12:15:48 -07:00
..
CMakeLists.txt HLSL: implement numthreads for compute shaders 2016-10-31 09:28:17 -06:00
hlslAttributes.cpp WIP: HLSL: Add GS support 2016-11-21 18:25:08 -07:00
hlslAttributes.h WIP: HLSL: Add GS support 2016-11-21 18:25:08 -07:00
hlslGrammar.cpp HLSL default function parameters 2016-12-29 12:15:48 -07:00
hlslGrammar.h HLSL default function parameters 2016-12-29 12:15:48 -07:00
hlslOpMap.cpp HLSL: Basic array grammar. 2016-06-19 11:50:34 -06:00
hlslOpMap.h HLSL: Add (almost) full expression grammar: Binary, unary (pre/post-fix), assign, ... 2016-05-03 23:33:00 -06:00
hlslParseables.cpp HLSL default function parameters 2016-12-29 12:15:48 -07:00
hlslParseables.h Add lerp, fix sincos return type, ret type tests, non-square mats, HLSL->AST tx semantics 2016-06-21 10:10:48 -06:00
hlslParseHelper.cpp HLSL default function parameters 2016-12-29 12:15:48 -07:00
hlslParseHelper.h HLSL default function parameters 2016-12-29 12:15:48 -07:00
hlslScanContext.cpp PP: Rationalize names of tokens. 2016-12-21 11:55:53 -07:00
hlslScanContext.h HLSL: Implement basic "struct" grammar. 2016-06-12 23:54:31 -06:00
hlslTokens.h WIP: HLSL: Add GS support 2016-11-21 18:25:08 -07:00
hlslTokenStream.cpp HLSL: Fix a grammar error related to constructors in parenthetical expressions 2016-07-30 08:09:09 -06:00
hlslTokenStream.h HLSL: Fix a grammar error related to constructors in parenthetical expressions 2016-07-30 08:09:09 -06:00