Using the position of an object to values in a script.

Hi there,

I have no idea how to do this (or if it’s even possible) but can you use the position of an object in your scene to control values in a shader?
I want to grab the x and y world pos of my camera and change the offset of a texture to create a slight parallax effect, but I have no idea how to use external objects in a shader.

Can anyone point me in the right direction?
Thanks,
Pete

Awsome, thanks!