Suggestion to change Unity's default compute shader code

Hello,

I have a suggestion for one of your shipped code examples, in particular, the Compute Shader that is generated by doing: Right click on project panel > Create > Shader > Compute Shader. My suggestion is to update the code so that the compute shader generates opaque pixels instead of transparent pixels. I mean to change the code line 13 from this:

Result[id.xy] = float4(id.x & id.y, (id.x & 15)/15.0, (id.y & 15)/15.0, 0.0);

to this:

Result[id.xy] = float4(id.x & id.y, (id.x & 15) / 15.0, (id.y & 15) / 15.0, 1.0);

My rationale is that for people prototyping solutions and trying to quickly visualize everything is properly glued (like myself), it is easier to visualize the compute shader results and that our modifications are correct if the pixels are opaque from the beginning in the example.

My suggestion is inspired by this question btw: How can I properly use a RenderTexture generated from a Compute Shader as the background of a VisualElement? - #3 by AlphaDrako099 … I spent more time debugging, trying things, and figuring out why the render texture was not shown as the VisualElement backgroundImage than assemblying my testbed protoype lol :sweat_smile: