Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

The Standard Shader

Discussion in 'Unity 5 Pre-order Beta' started by reptilebeats, Nov 4, 2014.

  1. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    hey i just thought i would post something i noticed with the standard shader which is really annoying, im not a shader expert though myself.

    so when using the height map with an AO map i notice that the AO does not stick/wrap with the change in height. so the AO will stay at its default position creating a very strange effect where the maps no longer sync up.
    i can post pictures if its a bit confusing to what i mean, minds gone blank today.

    also i would like to see an extra value to increase the brightness of the spec map and gloss map to create a shinier look during runtime.
     
  2. Roni92

    Roni92

    Joined:
    Nov 29, 2013
    Posts:
    225
    You are not supposed to work on material's channels directly in Unity editor. There are other software to do this. And when you are happy with results, you should just put channels textures into slots in Unity and it SHOULD look like in other soft where you made them(if lightning conditions are similar ofc.)
     
  3. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    whats the point of being able to increase/decrease the height map then
     
  4. the_motionblur

    the_motionblur

    Joined:
    Mar 4, 2008
    Posts:
    1,774
    You mean when using the height for paralax then AO does no warp outwards together with the displacement effect, right?
    Could you please post a screenshot? I want to know if I understood that correctly.
     
  5. Roni92

    Roni92

    Joined:
    Nov 29, 2013
    Posts:
    225
    Because you changing output of heightmap, not texture. But I agree with you, there could be adjustment for them too ;)
     
  6. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    give me five secs i will post a screen shot let me just make another example up as i deleted the previous one
     
  7. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    ok so here is the example, its not as bad as my original but these are textures from google that i was using to play with some stuff, so there deleted to prevent me from accidentally using them.

    it shows up at its worst when the height is at its extreme (very unlikely to ever be that high) but its only really noticeable on certain textures, this one is pretty good but you can still notice it a bit. my original had problems on the breaks of the wood.

    i did try my textures but couldn't notice it even at extreme.
     

    Attached Files:

    • test.jpg
      test.jpg
      File size:
      587.4 KB
      Views:
      1,056
  8. the_motionblur

    the_motionblur

    Joined:
    Mar 4, 2008
    Posts:
    1,774
    Okay - so it seems the problem is indeed that the AO masking remains stationary while the parallax mapping is pushing the texture outwards visually. After all the height mapping is merely an optical trick that does not change the geometry in this case.
    I don't think there's much you can do setting wise. If there is a solution to it then it probably has to be worked into the shader itself. Until then you could try if it looks better with a more diffuse AO without much definition (so that the drifting does not get so apparent) or you will simply have to use either AO or parallax for the time being.

    Maybe someone from Unity or someone who is good at shader programming can tell you more.
     
  9. Cascho01

    Cascho01

    Joined:
    Mar 19, 2010
    Posts:
    1,347
    I also have a general problem with the occlusion map:
    Why is it sticked on UV1???

    We can´t bake occlusion to a wall that uses UV1 for the bricks and UV2 for an environmental occlusion, right?

    This brings me to the general lightmapping issue with the standard shader as it is now (5.0.0b11):
    How to add lightmaps to the standard shader???
     
    Last edited: Nov 4, 2014