Hello.
I am currently trying to make a custom shader for a Spine animation (I'm currently using shader graph) but encountered a problem.
Let's say I want to cover my object with a white blob like this:
The issue is that I can only directly modify the original sprite atlas texture:
I am looking for a way to make a tranformation of texture from object space to sprite atlas space. First thing I tried was creating a custom UV texture for my blob texture so it would deform it according to the sprite atlas. But that was a failure because image quantization would distort my original texture. I am also thinking about generating a custom UV in script but both of these ideas are flawed in a way that they might not take into consideration the pose of the skeleton when the blob is applied to it as well as mesh deformations.
My another idea was (since my blob texture is procedurally generated anyway) to generate the texture to fit the sprite atlas right away.
What would be the best approach to implement this? Or is it even worth the hustle? That effect is a pretty minor thing in my game so I would like to avoid spending too much time on it. Might be a useful thing to know for the future, however.