Home Unreal Engine

Vertex Painting and Cubemaps ?

polycounter lvl 13
Offline / Send Message
Linkitch polycounter lvl 13
Alright I'm having some issues with getting Vertex Painting and Cubemaps to work together.

In the image below I've setup a material to simply add the the Cubemap together with the Diffuse, while controlling it based of the red channel of the Red vertex color.
This doesn't work, it doesn't seem to acknowledge the Vertex Color at all. No matter where I paint, the Cubemap is always present.

BfcKs.png

I found this thread from awhile back, and I tried to setup a material exactly like he has. But this gives me an error when I try to attach the Mask and Camera Vector.

URYKn.png

So what exactly am I doing wrong here?
I have other materials already made that work just fine with Vertex Painting, but as soon as I add a Cubemap into the mix, everything just screws up horribly.

Replies

  • Harbinger
    Options
    Offline / Send Message
    Harbinger polycounter lvl 8
    Shader 1:
    Currently there's a limitation with using the vertex color node with a transform node, you basically won't get any vertex colors.

    Shader 2:
    An actual cubemap lookup needs three components (X,Y and Z), your mask is only passing the red and green channel. In the case above you can either plug a normal 2d texture into the texture sample or plug the camera vector straight into the texture sample. Because you can't use a transform node combined with a vertex color, you won't be able to get a true cubemap lookup as far as I know.
  • JordanW
    Options
    Offline / Send Message
    JordanW polycounter lvl 19
    to Use reflection vector + vertex color enable per-pixel camera vector in your material properties.
  • Linkitch
    Options
    Offline / Send Message
    Linkitch polycounter lvl 13
    JordanW wrote: »
    to Use reflection vector + vertex color enable per-pixel camera vector in your material properties.
    Thanks so much! Been using way too long trying to figure this out.
  • Harbinger
    Options
    Offline / Send Message
    Harbinger polycounter lvl 8
    Nice!! Jordan, when was that added? Is there any performance trade-off?
Sign In or Register to comment.