Home Technical Talk

Anyone have more details on how to make a carpet in UE4

polycounter lvl 6
Offline / Send Message
Stu2Prof polycounter lvl 6
I found this page on the UE4 docs but its a little skimpy on the details for the material used. Has anyone found a full tutorial on doing shaggy carpeting in Unreal? Cheers for any help you can give

Replies

  • Kbrom12
    Options
    Offline / Send Message
    Kbrom12 polycounter lvl 8
    Epic gives you that scene, go open it up and see what they are doing.


  • Stu2Prof
    Options
    Offline / Send Message
    Stu2Prof polycounter lvl 6
    Thanks Kbrom12. I downloaded the project and have been looking at the material behind the carpet. It seems to make use of layered polygons, vertex colours and multiple bump offsets connected into the opacity mask. However I am still a little confused by the logic behind the material. If you know the answer could you help me understand a few things?

    1) Starting with the green channel of a bitmap file as an alpha the author creates 4 seperate bump offsets that add back into each other later on to create some form of cumulative effect. I believe this is to offset each polygon layer differently but I am a little confused how this can be acheived because the only distinguishing factor between them is the amount of redness in their vertex colours. In the Vertex Colour box below though you can see that the code is only able to process the blue channel of the vertex colours (The base polygon layer of the carpet is an absolute blue with the others going from straight red to black)

    2) In the examples below the author lerps between two values that are the same with the Green channel as an alpha. Isnt this pointless? I would assume the result from this combination would be the same output as a standard 1 vector parameter.



    3) In this setting the author is multiplying a vertex colour value by 0. Would this not reduce the output to 0 also? Making the following Lerp process another situation of lerping between the same value?

  • Mirbobo
    Options
    Offline / Send Message
    Depending on the result you want, you could also try using Parallax Occlusion Mapping node to achieve a similar result, I remember getting quite ok results with it and it was fast and easy to setup as well.
  • ZacD
    Options
    Online / Send Message
    ZacD ngon master
    There's also Neofur if you don't mind plug ins. 
Sign In or Register to comment.