Vertex Shader problem with _WorldSpaceCameraPos

Hey fellas,

I’m currently writing a vertex shader based on tanoshimis vertex shader published in this post “Moving vertices in shaders” where I want to translate the vertices based on my camera position.

I get the camera position from _WorldSpaceCameraPos . However, it seems like it doesn’t get updated every frame. The first frame is correct. But as soon as I rotate the camera, the translation sticks the way it was made when the camera was in its original position.

Any idea how to access this problem?

try:
float3 look = _WorldSpaceCameraPos - p[0].pos;