I can’t find a way to populate directly the Vertex Shader output (Varyings) using a computeshader.
I managed to run a computeshader in the render (unclear but still useful link: https://docs.unity3d.com/6000.0/Documentation/Manual/urp/render-graph-compute-shader-run.html) but I found nothing about “hacking” the output of the vertex shader, populating the Varyings though a GraphicsBuffer.
I could just run a simple vertex shader just reading the data from this buffer then putting it in the output, like o.positionCS = i.positionCS, and so on, but it really feels like a waste of resources/performance.
My triangles are special, sharing specific data among blocks of triangles, thus my need. I could bypass it by using the good old InstanceID, CommandID etc of instancing, each block being an instance
but then, I do continuously read the same data for multiple vertices, AND I do believe that computeshaders, at least in some situations, can be faster than vertex shaders (intrisics, shared memory, groupID and/or numthreads usage, etc).
Thanks for your help!