I wonder if theres a way to give all vertices different position information in shadergraph.
What i want to do is, to save the blendshape information of an object into a texture and use that texture, to
apply different positions for the vertices through shader.
Saving that information is the easy part.
But so far, i failed to understand how to set different positions to different vertices in shadergraph.
Is there a way to adress every verties with index, or to make one vertices use the information from one specific pixel of the texture?
Hi, you can use the vertex’s UV position (also called texture coordinate) to sample a texture2D (LOD 0) in the vertex stage. If there’re lots of vertices in the mesh, I think you’ll have to create a special UV (1 pixel → 1 vertex’s UV) for it.
Thank you for your reply. I’m not exactly sure, how your method works, but mentioning the UV gave me the right idea.
Ultimatly, i’m using the VertexID-Node with a bit of calculation to get the correct uv-coordinates for every pixel.
Works great, and as i hoped, i got a huge performance boost.