Ian Romanick
cb9cba20a0
Use glsl_type::element_type to get the type of array elements
2010-04-02 16:08:44 -07:00
Ian Romanick
c35bb00130
Ensure that 'in' and 'inout' formal parameters are valid lvalues
...
This causes the following tests to pass:
glslparsertest/shaders/function10.frag
2010-04-02 15:51:02 -07:00
Eric Anholt
c2cb84e17b
Add bool/int conversion as IR operations.
...
Fixes constructor-09.glsl and CorrectParse2.frag.
2010-04-02 11:22:41 -07:00
Eric Anholt
dc58b3f8cc
Add conversion of bool to float as an IR operation to match int to float.
2010-04-02 11:22:41 -07:00
Ian Romanick
00aa173c9c
Generate array constructor calls
2010-03-31 16:48:48 -07:00
Ian Romanick
68515ee6c2
Refactor parts of match_function_by_name into process_parameters and process_call
...
These will be used in the functions that implement calls to array constructors.
2010-03-31 16:28:51 -07:00
Ian Romanick
b6326abb85
Reject array constructor calls in GLSL 1.10
2010-03-31 16:25:21 -07:00
Ian Romanick
3e0ef5f81b
Use ast_type_specifier::glsl_type to get the type of a constructor
...
This is the first baby step towards getting array constructors working.
2010-03-31 16:22:56 -07:00
Ian Romanick
8a24cd5cea
Allow single-component constructors
...
This causes the following tests to pass:
glslparsertest/shaders/CorrectVersion.V110.frag
shaders/glsl-vs-sqrt-zero.frag
shaders/glsl-vs-sqrt-zero.vert
This causes the following tests to fail. These shaders were
previously failing to compile, but they were all failing for the wrong
reasons.
glslparsertest/shaders/attribute1.vert
glslparsertest/shaders/attribute2.vert
glslparsertest/shaders/main2.vert
2010-03-29 16:07:34 -07:00
Ian Romanick
0b7dcc80eb
Initial implementation of constructor handling code
...
All of the scalar, vector, and matrix constructors *except* "from
bool" constructors should be handled. Array and structure
constructors are also not yet handled.
2010-03-26 17:38:58 -07:00
Kenneth Graunke
fb9fb5f51d
Add new abstract ir_rvalue class; rework accordingly.
...
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-26 13:58:48 -07:00
Ian Romanick
abef955764
Begin processing constructors
...
Right now, reject constructors for samplers because the are illegal.
2010-03-23 15:08:30 -07:00
Ian Romanick
8bde4cec6b
Use glsl_symbol_table instead of using _mesa_symbol_table directly
2010-03-19 11:57:24 -07:00
Ian Romanick
f4749610ed
Factor guts of function matching code out to match_function_by_name
...
This function will be used for matching some types of constructors as well.
2010-03-15 13:26:02 -07:00
Ian Romanick
548fa293a3
Move ast_function_expression::hir to ast_function.cpp
2010-03-15 13:04:13 -07:00