FindLookAt equivalent for materials?

I need a material that can rotate a mesh (pitch and yaw only) to look at an arbitrary point in world space. Does anyone have any experience with such a thing?

For our project, we’re currently doing this on the CPU and it’s tanking performance. We don’t need collision, shadows, etc., so moving it to the shader is appealing if we can get it working.

You could do something like this

Instead of facing the camera, you could use a parameter collection to set the target point.

Heh, I actually ran through that video. The challenge came into when I tried to pitch on the Y axis at the same time. It broke my brain.

There are nodes, but I’ve never used them

Thanks, but those work great for aligning meshes to the camera, whereas I’m looking to align them to an arbitrary point in 3D space.

Yes, but instead of the camera location, you can specify a point?

( you can pop them open and copy the code, and rework it )