Open anshikavashistha opened 2 months ago
This PR implements support for the Assignment XOR token in the CrossGL project .The token is now properly translated across the DirectX, Metal, and OpenGL backends.
Close #112
shader ANDShader { vertex { input vec3 position; output vec2 vUV; void main() { vUV = position.xy 10.0; vUV.x &= 3.0; // AND assignment operator gl_Position = vec4(position, 1.0); } } fragment { input vec2 vUV; output vec4 fragColor; void main() { float noise = perlinNoise(vUV); float height = noise 10.0; height &= 2.0; // AND assignment operator vec3 color = vec3(height / 10.0, 1.0 - height / 10.0, 0.0); fragColor = vec4(color, 1.0); } } }
@samthakur587 PTAL
hii @anshikavashistha can you please solve the merge conflict .
PR Description
This PR implements support for the Assignment XOR token in the CrossGL project .The token is now properly translated across the DirectX, Metal, and OpenGL backends.
Related Issue
Close #112
shader Sample
shader ANDShader { vertex { input vec3 position; output vec2 vUV; void main() { vUV = position.xy 10.0; vUV.x &= 3.0; // AND assignment operator gl_Position = vec4(position, 1.0); } } fragment { input vec2 vUV; output vec4 fragColor; void main() { float noise = perlinNoise(vUV); float height = noise 10.0; height &= 2.0; // AND assignment operator vec3 color = vec3(height / 10.0, 1.0 - height / 10.0, 0.0); fragColor = vec4(color, 1.0); } } }
Checklist