Search Unity

  1. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  2. Improved Prefab workflow (includes Nested Prefabs!), 2D isometric Tilemap and more! Get the 2018.3 Beta now.
    Dismiss Notice
  3. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  4. Participate with students all over the world and build projects to teach people. Join now!
    Dismiss Notice
  5. Build games and experiences that can load instantly and without install. Explore the Project Tiny Preview today!
    Dismiss Notice
  6. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice
  7. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Nodes for Shader Graph

Discussion in 'Assets and Asset Store' started by Andrey_Graphics, Aug 2, 2018.

  1. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    http://u3d.as/1gkf

    13 Nodes:
    - SSS Colors,
    - SSS gradient,
    - Parallax mapping,
    - Parallax Mapping iterrations,
    - Parallax Occlusion Mapping,
    - PerturbedNormals (World normal with NormalMap),
    - CreateNormalChannel (for individual texture channels),
    - CreateNormalFloat (allows to use procedural noises and stuff to create normals),
    - IfNode,
    - LightDirection,
    - ProceduralRock (procedural noise),
    - Range (procedural shape),
    - TilingShape (for convenient tiling shapes).

    All nodes work with LWRP and with HDRP



     
    Last edited: Aug 21, 2018
    Grimreaper358 likes this.
  2. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Added a shader for vegetation made entirely in Shader Graph
     
  3. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Added sss node for Amplify Shader Editor for this Asset
     
    gasanoff and petersx like this.
  4. petersx

    petersx

    Joined:
    Mar 5, 2015
    Posts:
    191
    does it work in HDRP ?
     
    Andrey_Graphics likes this.
  5. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    All nodes operate HDRP and on LWRP, but "Amplify shader editor" itself does not support HDRP as far as I know
     
    Last edited: Aug 10, 2018
  6. petersx

    petersx

    Joined:
    Mar 5, 2015
    Posts:
    191
    Latest version of ASE works in HDRP
     
  7. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    When there is an opportunity I will check on the latest version of ASE and write to you, it should work.
     
  8. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    Really sweet to see this but pretty much all of these nodes are on their way to Shader graph as well as a Lit Master node to support all the HDRP shader features on the Standard Lit Shader. Although I can still see some nice uses for your node especially if they also work with LWRP since it doesn't have SSS and Translucency so I'm keeping an eye on this.
     
    Andrey_Graphics likes this.
  9. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    You can suggest which nodes I would add to the Shader Graph for the update, what else do you lack in Shader Graph?
     
  10. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    That's why I added the ability to use several colors / textures or use a gradient instead of one red as usual)

     

    Attached Files:

    Last edited: Aug 13, 2018
  11. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    Not quite sure, I'm guessing these nodes also work with LWRP since none of them are directly coded into the master node.
     
  12. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    All nodes work with LWRP and HDRP, all screenshots and videos (except for the plant) were made in the scene with LWRP, but I have another scene with HDRP. upload_2018-8-14_8-22-9.png
     
    Last edited: Aug 14, 2018
  13. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    All these nodes will be a nice to have especially working with LWRP. Will you also make some sort of transmission/translucent node to work with materials like cloth?
     
  14. RenOli

    RenOli

    Joined:
    Jan 23, 2013
    Posts:
    94
    Awesome, exactly what we need. Does it uses Unity Profile SSS?

    Is it in forward or deferred?
     
  15. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    Should work with both forward and deferred but it won't be using the SSS profiles since that's HDRP only. Instead, these nodes use colors/gradients to define how the SSS will look and in return, it works both with LWRP and HDRP.

    Devs are working on the Lit Master node for shader graph to work with HDRP and that will be able to use the SSS Profiles. https://github.com/Unity-Technologies/ScriptableRenderPipeline/tree/sg/lit-master-node
     
  16. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    You can set Transmission to make the light come out from the back
    upload_2018-8-15_10-58-19.png upload_2018-8-15_10-59-43.png upload_2018-8-15_11-0-10.png upload_2018-8-15_11-2-20.png
     
    Last edited: Aug 15, 2018
    Grimreaper358 likes this.
  17. sasob8

    sasob8

    Joined:
    Jul 11, 2017
    Posts:
    6
    Does your vegetation shader support wind AND translucency (or SSS)? When will it come to asset store?
    There is a great shader in recent unity blog for vegetation, but it doesn't have translucency, because shader graph does not support it as far as i know (i'm no coder :)).
     
    Andrey_Graphics likes this.
  18. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, I took as a basis the shader from the unity blog, so the shader supports the wind, the translucency works but the shadow in the Shader graph can not be obtained from the reverse side, if such an opportunity is added to the Shader graph, then I will update this shader (the material was made in HDRP ),
    Asset appeared on the Asset store

    http://u3d.as/1gkf

    upload_2018-8-21_13-27-45.png upload_2018-8-21_13-28-47.png upload_2018-8-21_13-29-0.png
     
    Last edited: Aug 21, 2018
  19. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
  20. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, at the moment in Amplify shader editor does not work Light Direction in HDRP, without it SSS will not work, I today already wrote to the developers of ASE
    upload_2018-8-23_18-41-7.png upload_2018-8-23_18-41-17.png
     
    Bartolomeus755 and petersx like this.
  21. petersx

    petersx

    Joined:
    Mar 5, 2015
    Posts:
    191
    What is a benefit of your implementation that implementation in ASE ? Material type: Subsurface Scattering ?
     
  22. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    It works with both LWRP and HDRP. Amplify's version is the same as the Default Lit shader in HDRP, just in their editor ASE so it will only work with HDRP.
     
    petersx and Andrey_Graphics like this.
  23. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Compared to the standard method, it is faster and more customizable, and you can also use textures for each layer, and in LWRP there is no SSS, my implementation works in LWRP
     
    Last edited: Aug 23, 2018
    petersx likes this.
  24. ArchVizPRO

    ArchVizPRO

    Joined:
    Apr 27, 2014
    Posts:
    298
    Hello
    I am using the "NodeParallaxOcclusionMapping" in HDRP.
    In Editor works ok... but I can't build because I got several errors.
    Capture.JPG
    Any idea how to solve it?
     
  25. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, thank you for letting me know about this issue, I fixed this problem, I will send you an unitypackage to Email, email me industrialforest@mail.ua
     
    Last edited: Aug 25, 2018
  26. lorddesu

    lorddesu

    Joined:
    Aug 20, 2014
    Posts:
    6
    What about tessellation? Is it even possible in SG for now?
     
  27. Kareeem

    Kareeem

    Joined:
    Mar 1, 2013
    Posts:
    19
    This is amazing! Thanks for this, good price too!
    Is it possible to bake Shallow Maps out of outer software? I am new to the SSS Concept...
     
  28. Kareeem

    Kareeem

    Joined:
    Mar 1, 2013
    Posts:
    19
    Also what would be really cool: A Unlit Shader wich recieves shadows from dynamic objects. Because i would like to bake my lighting outside of unity and use a unlit shader on those objects.
     
  29. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, do you want to bake lighting, color, and sss, all in one texture?
    I don't know how to bake SSS in texture.
     
    Last edited: Oct 13, 2018
  30. Kareeem

    Kareeem

    Joined:
    Mar 1, 2013
    Posts:
    19
    Hi,
    I think I just would like to know where and how to bake these textures from a mesh or do you have to paint them in photoshop?

    Unbenannt.PNG
     
  31. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Sorry, I did not understand you correctly at first, I baked these textures in Xnormal, this is a thickness map, they can also be baked in other programs, for example, Substance Designer upload_2018-10-14_9-28-23.png upload_2018-10-14_9-29-41.png
     
  32. Kareeem

    Kareeem

    Joined:
    Mar 1, 2013
    Posts:
    19
    Sweet, thanks a lot!
     
  33. Kareeem

    Kareeem

    Joined:
    Mar 1, 2013
    Posts:
    19
    Tried XNormal. Translucency map worked fine but the thickness texture looks messed up.
    I put the low poly mesh in both channels in Xnormal. High and Low...
     

    Attached Files:

  34. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Use the translucency map instead of the thickness map, it's almost the same
     
  35. Knipscher

    Knipscher

    Joined:
    Jun 20, 2018
    Posts:
    31
    Extremely helpful asset, thank you for making it!
     
    Andrey_Graphics likes this.
  36. agreeablegames

    agreeablegames

    Joined:
    Nov 20, 2016
    Posts:
    13
    Great asset, I bought it just for the SSS shader on Amplify for the LWRP pipeline.

    I would really like some kind of refraction node that works in Amplify's LWRP pipeline. For example, looking through a magnifying glass or a glass of liquid. Since they don't allow grab screen color in LWRP, I couldn't think of a way to make one.

    Thanks!
     
  37. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, thanks for your feedback, later I will add "light attenuation" (shadow receiver in ASE and Shader Graph), refraction node I tried to do, failed. You can try using Render texture, I added a second camera and forbade it to render the sphere.
    upload_2018-11-10_9-19-45.png
    upload_2018-11-10_9-21-47.png
    upload_2018-11-10_9-23-55.png
     
  38. agreeablegames

    agreeablegames

    Joined:
    Nov 20, 2016
    Posts:
    13
    @Andrey_Graphics Thanks for the idea with the rendertexture.

    I managed to get something working with the new version of ASE on their website and the 'Grab Screen Color' node. It uses the opaque texture feature recently added to the LWRP pipeline. I'm still tweaking the effect and I'm sure someone with more shader knowledge such as yourself could do a better job.




     
    gasanoff likes this.
  39. Jef_thefridge

    Jef_thefridge

    Joined:
    Dec 11, 2017
    Posts:
    1
    Hi there @Andrey_Graphics

    We bought your asset "Nodes for Shader Graph" for Unity and were hoping to use it for the Parallax Occlusion Mapping, since the PBR Shader has no height map.

    The nodes you made are really good, but we've come across two significant issues:

    1. On a plane, the parallax effect freaks out once you scale the plane to a normal size. In the project you provided, everything is scaled down to around 0.1. If you scale it up to 1, everything looks weird.

    2. On a 3D object, the parallax effect seems to only work correctly in the Y-axis. When rotating the object, the result is really weird. (same when rotating a plane)

    Are these issues you're aware of? And does a fix exist?
     
  40. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, I didn't know about it, thanks for letting me know, I'll take care of it.
     
    Jef_thefridge likes this.
  41. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    New version on the asset store.

    Added node "Light Attenuation" (receive shadows) as well for ASE, I advise you to combine with SSS nodes;
    All nodes are fixed Parallax;
    Added node "NodeFixedViewDirectionTangent", in Shader graph ViewDirectionTangent incorrect because of what Parallax does not work properly,
    this added a fixed node" ViewDirectionTangent",
    do not use the standard version until it is fixed by the developers of Shader graph,
    use my node, it works correctly.
     
    Last edited: Nov 26, 2018
  42. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    348
    Does the new version support SRP 5.x.x versions with Unity 2019.1? (Currently Alpha)
     
  43. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hi, Yes, but in the new version of shader graph there are serious bugs, I would not use it, the main bug - if you use color, gradient or float variable and the value is not integer (eg 0.5) the Shader will not work, I hope these bugs will soon fix the developers shader graph.
     
  44. Shiyao

    Shiyao

    Joined:
    Nov 27, 2013
    Posts:
    20
    Will you add a node for eye ball?
     
  45. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    Hello, what should this node do? I do not quite understand
     
  46. Shiyao

    Shiyao

    Joined:
    Nov 27, 2013
    Posts:
    20
    First, on side view, pupil should has refraction.
    upload_2018-12-10_0-16-50.png

    Second, inside of pupil is sunken as bottom image.
    upload_2018-12-10_0-21-11.png

    Images are from this video
     
  47. Shiyao

    Shiyao

    Joined:
    Nov 27, 2013
    Posts:
    20
    I think hair shader also has a great demand.
     
  48. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    It will be difficult to make such a node with 0, so if I had such a Shader on unity, no matter in which render pipeline, so that I could see how the code did it, then I could do it for Shader graph. Most likely need refraction, for the correct effect, but refraction in Shader graph does not work.
     
  49. Andrey_Graphics

    Andrey_Graphics

    Joined:
    Oct 29, 2015
    Posts:
    48
    About hair I thought before, perhaps will make in the future Shader but not see sense to do node for hair
     
  50. Shiyao

    Shiyao

    Joined:
    Nov 27, 2013
    Posts:
    20
    Thanks for your quick reply. I am looking forward to your amazing update.