|
5601ea0d
|
2011-06-10T18:23:25
|
|
Implement ES2 backend for Angle translator.
With this CL, we have the option to select a code output backend: GLSL, GLSL ES, or HLSL.
Note that we always emit the highest supported float precision for fragment shader due to anglebug 168. Although this is a temporary solution, it's not against GLSL ES spec, because it's ok for implementation to upgrade precision.
Tested with WebGL conformance test suite, GLES2 conformance test suite (only failed 2/1198), and a few webgl demos, including worlds of webgl, aquarium, etc.
anglebug=81
test=translator emitting correct GLSL ES code when ES2 backend is selected.
Review URL: http://codereview.appspot.com/4550129
git-svn-id: https://angleproject.googlecode.com/svn/trunk@687 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
0b8d4eb2
|
2011-04-04T19:17:11
|
|
Unroll for-loop if sampler array uses loop index as its index.
If inside a for-loop, sampler array index is the loop index, Mac cg compiler will crash. This CL unroll the loop in such situation. The behavior is:
1) If the for-loop index is a float, we reject the shader.
2) If it is an integer, we unroll the for-loop.
Things that should be done in the future are:
1) Add line number macros.
2) Add a limit to unroll iteration count.
anglebug=94
Review URL: http://codereview.appspot.com/4331048
git-svn-id: https://angleproject.googlecode.com/svn/trunk@606 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
52813558
|
2010-11-16T18:36:09
|
|
Replaced TIntermLoop::testFirst with TIntermLoop::loopType to clearly indicate which type of loop it is. In some cases it is not possble to differentiate between a for-loop and while-loop.
BUG=48
Review URL: http://codereview.appspot.com/3123041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@482 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
95447df0
|
2010-10-14T16:09:37
|
|
GLSL backend was assuming that a for-loop will always have a condition. But according to GLSL ES 1.0, the condition is optional.
BUG=50
Review URL: http://codereview.appspot.com/2489042
git-svn-id: https://angleproject.googlecode.com/svn/trunk@451 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
06098890
|
2010-08-26T19:36:42
|
|
Allow derivative functions if derivative extension is enabled. I still need to add validation for "#extension GL_OES_standard_derivatives : enable".
BUG=25
Review URL: http://codereview.appspot.com/1965045
git-svn-id: https://angleproject.googlecode.com/svn/trunk@403 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
434fdf21
|
2010-08-09T22:31:36
|
|
Fix warnings about unused variables. Submitted by timeless.
BUG=15
Review URL: http://codereview.appspot.com/1916046
git-svn-id: https://angleproject.googlecode.com/svn/trunk@379 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
003e7b13
|
2010-08-09T17:14:46
|
|
We were trying to change a const_iterator which was rightly caught by SunStudio compiler. Submitted by Eagle.Lu.
BUG=19
Review URL: http://codereview.appspot.com/1879049
git-svn-id: https://angleproject.googlecode.com/svn/trunk@374 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
5eb4609c
|
2010-07-26T18:15:21
|
|
Encapsulate expressions with ternary operators with brackets. This preserves the order of precedence when ternary expressions are used in a compound expression.
BUG=20
Review URL: http://codereview.appspot.com/1894041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@352 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
cba04990
|
2010-06-14T20:36:41
|
|
Added parentheses around a few operators so that if they are used in a compound statement, order of operations is preserved.
BUG=5
TEST=OpenGL ES 2.0 conformance tests.
Review URL: http://codereview.appspot.com/1691041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@336 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
334aa1f3
|
2010-06-11T23:38:29
|
|
Handled case where selection nodes that use ternary operators are part of a sequence. Usually they are part of an assignment.
BUG=4
TEST=OpenGL ES 2.0 conformance tests, specifically operators test.
Review URL: http://codereview.appspot.com/1643043
git-svn-id: https://angleproject.googlecode.com/svn/trunk@335 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
91b72320
|
2010-06-02T15:50:56
|
|
Removed the dependency of compiler on common. This is done to make compiler self-sufficient so that it is easier to consume by external developers. I tried to replace all instances of assert by simply redefining assert(x) to ASSERT(x), but was getting a lot of compile errors. I still need to investigate that.
Review URL: http://codereview.appspot.com/1461041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@323 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
4e4facd4
|
2010-06-02T15:21:22
|
|
Refactored InfoSink. I have replaced most instances of sprintf with std::ostringstream to make it safer. I have made sure that everything still compiles and passes conformance tests.
Review URL: http://codereview.appspot.com/1391041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@322 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
13b2dd87
|
2010-05-26T18:35:23
|
|
Used "not" instead of "!" for vectors.
Review URL: http://codereview.appspot.com/1324041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@318 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
d88b7736
|
2010-05-26T15:13:14
|
|
Do not write extraneous semi-colons - some glsl compilers are do not like that even though it is so easy to ignore.
Review URL: http://codereview.appspot.com/1301041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@317 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
194522f6
|
2010-05-06T19:09:26
|
|
Fixed all issues with variable and function argument declaration. Multiple declarations of arrays in the same line had bugs. Also sepearated out declaration of varaibles and function arguments which makes it easier to understand.
Review URL: http://codereview.appspot.com/1142041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@242 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
b3f7fb68
|
2010-05-05T18:21:51
|
|
Recursively write ConstantUnion to correctly construct structs.
Review URL: http://codereview.appspot.com/1108041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@229 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
6ff56fd4
|
2010-05-05T16:37:50
|
|
Renamed constUnion class to ConstantUnion.
Review URL: http://codereview.appspot.com/1106042
git-svn-id: https://angleproject.googlecode.com/svn/trunk@227 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
a499cfc5
|
2010-05-03T23:14:49
|
|
Fixed multiple issues with struct declaration and construction.
Review URL: http://codereview.appspot.com/1076041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@220 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
2986a8cb
|
2010-04-30T22:32:32
|
|
Implemented a bunch of missing constructs.
Review URL: http://codereview.appspot.com/1031045
git-svn-id: https://angleproject.googlecode.com/svn/trunk@219 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
bbf56f75
|
2010-04-20T18:52:13
|
|
Use directory qualified #include files
Trac #11408
Signed-off-by: Andrew Lewycky
Signed-off-by: Nicolas Capens
git-svn-id: https://angleproject.googlecode.com/svn/trunk@165 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
376e1064
|
2010-03-31T20:25:53
|
|
Added support for loops.
Review URL: http://codereview.appspot.com/802047
git-svn-id: https://angleproject.googlecode.com/svn/trunk@91 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
3d270782
|
2010-03-30T20:33:38
|
|
Changes to pass 'abs' conformance tests.
Review URL: http://codereview.appspot.com/858041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@90 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
dd037b2a
|
2010-03-30T18:47:20
|
|
Added support for user-defined structs. And fixed a bug in function return type.
Review URL: http://codereview.appspot.com/849042
git-svn-id: https://angleproject.googlecode.com/svn/trunk@88 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
4388487c
|
2010-03-30T00:08:52
|
|
Moved code to unmangle function name to a common place and used it in both OutputGLSL and OutputHLSL.
Review URL: http://codereview.appspot.com/838041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@83 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
60fe407c
|
2010-03-29T20:58:29
|
|
Added TIntermSelection::usesTernaryOperator() to distinguish between selection nodes using ternary operator and if-else. Used in both OutputGLSL and OutputHLSL.
Review URL: http://codereview.appspot.com/830042
git-svn-id: https://angleproject.googlecode.com/svn/trunk@82 736b8ea6-26fd-11df-bfd4-992fa37f6226
|
|
76b82085
|
2010-03-24T17:59:39
|
|
Added GLSL backend for ESSL translator.
Review URL: http://codereview.appspot.com/698041
git-svn-id: https://angleproject.googlecode.com/svn/trunk@69 736b8ea6-26fd-11df-bfd4-992fa37f6226
|