Is there any way to create a Cube Render Target in Blueprints?

Basically what the title says… I’m used to being able to create render targets for Capture2D components, but there doesn’t appear to be any node for creating a cube render target…

there isn’t. you just add it as a component to your bp

Not sure what you mean by this, my issue is with the render target asset (the thing the capture component renders its texture into) not the component.

I’m trying to procedurally generate cubemaps in the construction script, so that I don’t have to keep manually creating render target assets for each capture in the scene.

sorry i got confused. but the answer is still no, there isn’t, sorry

This is the Capture2D equivalent of what I’m trying to do.

I can’t find a “Create Render Target Cube” blueprint function or anything similar.

But i will settle for just being able to write the cubemap texture to a directory. Anything to avoid having to manually create/assign a render target every single time I place the actor. Unfortunately “Render Target Create Static Texture” ALSO has no cubemap variant…

hmmm… you can create a cube render target with 6x 2d captures :slight_smile:
hey, if it works…

you can even optimize it a great deal by recapuring each face at a different interval. some games do each side on a different frame and some games update the top and bottom less frequent.
so many options…

How am I supposed to sample this as a cubemap in my material?

lat-long conversion + some math
maybe a mesh with some clever UVs
get creative

This is for an fake interior, a mesh won’t work.

LongLat conversion may but I’d need to somehow stitch all the sides together which I’m not sure how to do.

Thanks for the suggestion, I’ll have to think of how to do this.

Create a cube render target for the editor:


This duplicates a base texture (just a dummy) because “CreateAsset” doesn’t make a valid texture until the editor restarts. The parent class may be different for your version (I’m on 4.20), but you just need to use an editor-only blueprint so you can access editor-only nodes.

2 Likes

It works! You’re my hero man, thanks so much

1 Like