Announcement

Collapse
No announcement yet.

World Space nodes in Material Editor

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

    World Space nodes in Material Editor

    Does anyone have any resources that better explain how to use the world space nodes in the material editor? I understand that world space is the absolute coordinate for objects and such but putting that in practice in the material editor I just draw a blank on how to use them.

    Thanks in advance

    #2
    IT can be used for various things, the major one I know of is changing objects color based on world position. This is helpful for adding variety to the level's foliage.

    https://www.youtube.com/watch?v=W2fN9r4MfLY

    Comment


      #3
      There are lots of different ways of utilizing these nodes. Here's just 3 material graphs I've posted lately, all of them including 'world space' nodes.
      Terrain Texturing: https://forums.unrealengine.com/show...ll=1#post92322
      Foliage Vertex Shader: https://forums.unrealengine.com/show...ll=1#post91355
      Auto-Blend Textures: https://forums.unrealengine.com/show...ll=1#post91784
      3.14159265359

      Comment


        #4
        Oh very nice. Thank you for the responses guys! This helps a lot.

        @ Malkav!an: I noticed in the examples as well as other examples I've seen people use a clamp node a lot. Why is that? Do the world coordinates or certain nodes only go from 0-1 or something?

        Comment


          #5
          Originally posted by Killer Ferret View Post
          @ Malkav!an: I noticed in the examples as well as other examples I've seen people use a clamp node a lot. Why is that? Do the world coordinates or certain nodes only go from 0-1 or something?
          Certain nodes yes, but the world coordinates go from something like -524288 to 524288.


          Quite often it's because Lerp nodes need the alpha input to be within 0-1 range. Sometimes it's just to have a good value to work with since anything in world space tends to return some pretty large numbers, so you clamp it to 1 or another reasonable value. Also the values might be negative so you clamp the minimum to zero.
          3.14159265359

          Comment


            #6
            Originally posted by mAlkAv!An View Post
            Certain nodes yes, but the world coordinates go from something like -524288 to 524288.


            Quite often it's because Lerp nodes need the alpha input to be within 0-1 range. Sometimes it's just to have a good value to work with since anything in world space tends to return some pretty large numbers, so you clamp it to 1 or another reasonable value. Also the values might be negative so you clamp the minimum to zero.
            Interesting, that's good to know. Thank you for the explanation! I never realized how much truth there is in the saying "the more you know the more you realize how much you don't know" till I entered game development.

            Comment

            Working...
            X