diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-01-16 12:54:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-16 12:54:06 +0100 |
commit | e329cd60052f2dbfcca5bf2750672a3c2ca9dfa5 (patch) | |
tree | 6dad989cd61c33dac1772851a58bd333e9f9d111 /drivers | |
parent | fc2550c4c8e9ca4ee7378af0330544695d04d6c8 (diff) | |
parent | 5098232ee695ceca8d8e4536ac7cb142b0805abb (diff) |
Merge pull request #35189 from Chaosus/disable_gles2_array_init
Disabled array initialization, const array and arr.length in GLES2 shaders
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gles2/shader_compiler_gles2.cpp | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/drivers/gles2/shader_compiler_gles2.cpp b/drivers/gles2/shader_compiler_gles2.cpp index fc59486090..24b89aedc2 100644 --- a/drivers/gles2/shader_compiler_gles2.cpp +++ b/drivers/gles2/shader_compiler_gles2.cpp @@ -522,9 +522,6 @@ String ShaderCompilerGLES2::_dump_node_code(SL::Node *p_node, int p_level, Gener SL::ArrayDeclarationNode *arr_dec_node = (SL::ArrayDeclarationNode *)p_node; StringBuffer<> declaration; - if (arr_dec_node->is_const) { - declaration += "const "; - } declaration += _prestr(arr_dec_node->precision); declaration += _typestr(arr_dec_node->datatype); @@ -540,22 +537,6 @@ String ShaderCompilerGLES2::_dump_node_code(SL::Node *p_node, int p_level, Gener declaration += "["; declaration += itos(arr_dec_node->declarations[i].size); declaration += "]"; - int sz = arr_dec_node->declarations[i].initializer.size(); - if (sz > 0) { - declaration += "="; - declaration += _typestr(arr_dec_node->datatype); - declaration += "["; - declaration += itos(sz); - declaration += "]"; - declaration += "("; - for (int j = 0; j < sz; j++) { - declaration += _dump_node_code(arr_dec_node->declarations[i].initializer[j], p_level, r_gen_code, p_actions, p_default_actions, p_assigning); - if (j != sz - 1) { - declaration += ", "; - } - } - declaration += ")"; - } } code += declaration.as_string(); |