Camera projection - CameraVectorWS

Hello everyone;

I’m trying to create a camera projected texture. It looks like it’s possible to use the CameraVectorWS node in the material editor to project a texture from the current camera, but it’s not quite what I’m looking for.

Instead, I’d like to project a series of textures from a series of static cameras. Is there an equivalent to the CameraVectorWS would let me create a projection from an arbitrary camera?

Many thanks


you might want to look into using the TransformToZVector node to transform the world position. just plug the desired “camera” vector into the Z Vector socket and mask the result by R & G to get world projected UVs aligned with your vector.


Thanks for the reply! - I’ll give that a go.


I’ve made some good progress on this today - with a lot of help from This nuke tutorial on position pass projection


Here’s the material:


And here’s the blueprint that spawns the projection camera, and attaches a decal to it


Still having some issues, though.

Issue 1: Using the ‘TransformToZVector’ node works perfectly (Thanks divi!) - but only if the camera has no Z rotation. I’ve been trying to use the ‘RotateAboutAxis’ node to rotate the world position data to account for camera Z rotation, but for some reason it breaks everything.

Issue 2: The projection appears both in front AND behind the camera. The texture edges also ‘smear’ to infinity (the screenshot only looks good because the underlying texture is emissive, and the edges of the projection are black). Not sure how to remove everything outside the camera field of view.

Seems like it’s almost there - does anyone have any suggestions of how to get these kinks worked out?

Many thanks


the decal size is measured from the center of the decal box iirc, so you’ll have to offset the decal location along the camera vector by half the size for not having it affect the camera and everything behind it.

Hmm, I’m not sure 100%, but your screen looks like light with enabled light function. Maybe you can just use that?

I’m trying to project a full material, to allow VFX-style matte painting projections in unreal.

My test uses an emissive material (that looks like a light function) for testing. Appreciate the suggestion - but in this case no, I can’t.

I’ve finally got it all working.

Pixel-perfect camera projections in Unreal Engine!

Ran into some issues with skylights and deferred decals, which seems to be an ongoing issue with the engine - but the camera projection element worked fine. Here’s my ugly ‘proof of concept’:

It’s a blueprint + a material - what’s the most elegant way to package this up so I can share it?

A screen grab of the material layout and blueprint like you posted above feels enough. I’d love to see it as I’m trying to set something similar up.

Wow this is great, yea screenshots of the material and blueprint would be enough :slight_smile:

Hey Scribbler, your approach looks awesome. It would be really cool if you could post some screenshots. Thanks!

Edit: Never mind… I found it Projection Mapping technique to projects video files on objects? - Rendering - Epic Developer Community Forums

Hi @_Scribbler Would you mind resharing the BP? After the forum migration some screenshot above are gone

1 Like

I need to dig the tool out for a project I’m working on - haven’t touched it for a while. May take a bit of time to post it here, but I’ll see what I can do!


Hi _Scribbler, I’d love to see how you made this as I am a Matte Painter trying out Unreal Engine, would it be possible to post screenshots of the graphs?

Thanks in advance!

This is at the top of google, still relevant if you could repost Thanks!

For what it is worth there is a tutorial for this on the learning hub: Projecting a Texture in Worldspace | Tutorial

The tutorial assumes you’re going to be using a scene capture, but it should work just as well if your goal is to just project from a camera.

Thank you! huge help.

1 Like