Announcement

Collapse
No announcement yet.

Rotate normals based on camera for better foliage rendering

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Rotate normals based on camera for better foliage rendering

    I happened to stumble over the change log from Unigine where they implemented a cool trick to improve foliage shading.
    This helps reducing the harsh shading from low poly cards used for trees or grass.

    From what I understood, they are changing the vertex normal? so that it faces the camera.
    Does anyone of you guys have an idea of how they are doing this and if it is possible to implement the same technique in Unreal?

    Click image for larger version

Name:	RotateNormal_01.jpg
Views:	1
Size:	149.1 KB
ID:	1617213
    Click image for larger version

Name:	RotateNormal_02.jpg
Views:	1
Size:	152.8 KB
ID:	1617214
    Click image for larger version

Name:	RotateNormal_04.jpg
Views:	1
Size:	176.0 KB
ID:	1617215
    Click image for larger version

Name:	RotateNormal_03.jpg
Views:	1
Size:	178.5 KB
ID:	1617216

    https://www.artstation.com/klass

    #2
    Bumping this thread just in-case someone with with knowledge hasn't seen it.
    https://www.artstation.com/klass

    Comment


      #3
      I can't see a huge amount of difference in that asset to be honest.

      Have a look at this:
      https://forums.unrealengine.com/unre...HQ=&viewfull=1

      Comment


        #4
        Originally posted by TheJamsh View Post
        I can't see a huge amount of difference in that asset to be honest.

        Have a look at this:
        https://forums.unrealengine.com/unre...HQ=&viewfull=1
        Yeah its a bit hard to see it the screenshots I provided, but maybe you can see it better over here using the slider. This definitely helps with reducing the visibility of the cards by consolidating the overall shading of the tree. I can potentially do this by modifying the vertex normals of the cards but the results aren't always perfect.
        https://developer.unigine.com/en/doc...ated_to_camera
        Last edited by Klass; 05-13-2019, 04:46 AM.
        https://www.artstation.com/klass

        Comment


          #5
          Yeah it's quite subtle. I think the pixel-depth method Epic uses has a much more noticeable effect on giving billboards subtle depth information.

          As for this approach, you can rotate the normals towards the camera in the material graph, there may even be a material function for it already.
          Last edited by TheJamsh; 05-13-2019, 04:46 AM.

          Comment


            #6
            I use the pixel depth offset for the imposter rendering in order to get detailed shadowing on the billboards yeah. I will check if there is a material function already done for this.
            https://www.artstation.com/klass

            Comment


              #7
              I scrubbed through the livestream and couldn't find anything on using pixel depth offset. Can someone clear up exactly how you're using it to achieve better shadowing?

              To reference Unigine again, I assume it's similar to what they're doing with a "depth texture" on imposter billboards?

              Comment


                #8
                Pretty sure the Pixel Depth Offset is only used for foliage billboards to reduce artifacts from DFAO.
                Lighting Artist II @ Crystal Dynamics
                Former Lighting Artist @ Obsidian Entertainment
                ArtStation

                Comment


                  #9
                  Originally posted by rosegoldslugs View Post
                  Pretty sure the Pixel Depth Offset is only used for foliage billboards to reduce artifacts from DFAO.
                  More than that, you can do all sort of things with it. The name is explanatory, you can use that for offseting pixels and that will be fed to the depth buffer. This can also be used for calculating screen space shadowing for example. You can also use it with a temporal AA dither to reduce harsh seam transitions between two meshes or landscape etc...
                  https://www.artstation.com/klass

                  Comment


                    #10
                    Originally posted by Klass View Post

                    More than that, you can do all sort of things with it. The name is explanatory, you can use that for offseting pixels and that will be fed to the depth buffer. This can also be used for calculating screen space shadowing for example. You can also use it with a temporal AA dither to reduce harsh seam transitions between two meshes or landscape etc...
                    Oh I'm familiar with the uses, I was just mentioning it in regard to the posts above mine questioning Epic's use of it for foliage.
                    Lighting Artist II @ Crystal Dynamics
                    Former Lighting Artist @ Obsidian Entertainment
                    ArtStation

                    Comment


                      #11
                      Originally posted by rosegoldslugs View Post

                      Oh I'm familiar with the uses, I was just mentioning it in regard to the posts above mine questioning Epic's use of it for foliage.
                      My bad, I thought you were talking about the general use of it. Epic uses it for reducing DFAO artifacts indeed. I think you can also use to get some extra detail when using contact shadows on the foliage billboards.
                      This works well with POM materials for example.
                      Last edited by Klass; 05-14-2019, 06:06 PM.
                      https://www.artstation.com/klass

                      Comment

                      Working...
                      X