The generated shader code (gles3.0) may have some problem. Shader Code like this: (value>>8)&8 ; will generate: bitfieldExtract(value,8,8); But the problem is bitfieldExtract is not supported by gles3.0. I want to know is there any good method to solve this problem? Thanks!
Thanks for your reply. I have try: #pragma target es3.0 #pragma target 3.0 #pragma target 3.5 But make no sense. Error will output: 0(33) : error C7532: global function bitfieldExtract requires "#version 400" or later 0(33) : error C0000: ... or #extension GL_ARB_gpu_shader5 : enable I think maybe it's a bug on gles platform of unity. Actually,if unity do nothing with the >>&,the shader will work well...
You might need to report it as a big then. A cursory internet search showed the same bug happening in some non-Unity projects, so it might be some library Unity uses that’s behaving badly.
What are you trying to do? If you want to read a bit, you can do it with a divide and a modulo: (number / (2^bit position) %2