2

I have a Window projected texture and a fixed camera. The texture was made in another program based on a render of the scene. As long as I am looking through the camera, the texture is lined up properly. But if I switch to the viewport camera, then the texture is projected from the viewport, and so looks wrong.

Is there a way to do something like Window projection, but have it always be projected from the Active Camera (or object I can place in the same location), and not the viewport? Preferably a node based solution. I understand that the UV project modifier might work for this, but then I have to maintain that on every object in the project rather than just adding some nodes to a group.

Ascalon
  • 6,579
  • 8
  • 55
  • 121
  • Sorry if that seems obvious, but did you tried with a Camera (instead of Window) texture coordinate? – thibsert Sep 16 '19 at 18:40
  • 1
    Good question. Had probably the same issue a while ago. Rich's solution might help in this case too: https://blender.stackexchange.com/questions/121210/camera-projection-without-generating-uvs – brockmann Sep 17 '19 at 07:48

1 Answers1

3

This setup projects texture from camera and adjusts scale based on Z depth.

Works only in camera/perspective mode due to Z-depth socket used in calculations, viewport zooming doesn't affect texture scaling also due to Z-depth.

enter image description here

Serge L
  • 3,915
  • 1
  • 17
  • 33