Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

ShaderGraph/LW how to create a simple lit graph?

Discussion in 'Graphics Experimental Previews' started by demonixis, Oct 29, 2018.

  1. demonixis

    demonixis

    Joined:
    Aug 20, 2013
    Posts:
    93
    Hello,

    It seems that it's not yet possible to create a non PBR graph with the lightweight render pipeline and shadergraph. Is this feature planned or not?
     
    noio and adslitw like this.
  2. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
    Bump because I asked this same question a while ago and didn't get an answer either. As is stands I'm assuming we should use the unlit graph and implement our own simple lighting - is that right? Or is a simple lit graph on the way?
     
  3. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
  4. phil_lira

    phil_lira

    Unity Technologies

    Joined:
    Dec 17, 2014
    Posts:
    385
    Hi, not stupid at all. :D I'm not exactly sure if a non-PBS graph is planned and if so, what's the ETA. I'll find out.
     
    Hardev and adslitw like this.
  5. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,379
    Just out of curiousity, what kind of non PBR stuff that you guys talking about? NPR?
     
  6. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
    @Reanimate_L basically in LWRP there's a 'simple lighting' standard shader, which I'm assuming is more performant than the PBR shader, but when using the shader graph you can only choose from PBR or Unlit.

    But maybe the performance impact is negligible - I'll be honest I haven't profiled. But I'm making another assumption that the simple lighting shader exists for a reason!
     
    hippocoder likes this.
  7. demonixis

    demonixis

    Joined:
    Aug 20, 2013
    Posts:
    93
    The SimpleLit shader is not physcally based, just simple lighting, like the old diffuse. It's good for some mobile applications, and also for mobile VR/AR.
     
  8. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,379
    hmm i think it possible to create simple diffuse with the current lwrp. i remember some one manage to create custom toon shading in lwrp.
     
  9. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
    That was @Andy-Touch and he implemented his own simple lighting in shadergraph - not using any scene light data etc.
     
  10. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,379
  11. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
    noio likes this.
  12. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,379
    well then you can only wait from unity team then
     
  13. GameDevCouple_I

    GameDevCouple_I

    Joined:
    Oct 5, 2013
    Posts:
    2,126
    or write a custom master node, although I still havent worked out how to do this! Woud love to though as it opens up shader graph for any shader type
     
  14. Knipscher

    Knipscher

    Joined:
    Jun 20, 2018
    Posts:
    63
    Yes, it seems like this isn't possible and for this reason it seems like it's also not possible to use, for example, the HDRP subsurface scattering presets with Shader Graph. Is that planned at all for the future?
     
  15. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    572
    This is already in, and for a long time now. Right now there aren't full docs for anything. SRP Core, LWRP, and Shader Graph are all coming out of Experimental/Preview with the release of Unity 2019.1 so you can expect the documentation for those to come with the release, then things should be more clear.

    upload_2018-11-16_21-13-30.png
    upload_2018-11-16_21-14-47.png
     
  16. Knipscher

    Knipscher

    Joined:
    Jun 20, 2018
    Posts:
    63
    Yes, it would be great to have information on how to do that. How do you open the Lit shader in the ShaderGraph? I can only seem to get to the PBR shader.
     
  17. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    572
    You need to be using a version of HDRP that includes the Lit Master node and a version of Unity that supports it. I recommend updating to the latest beta of Unity 2018 with is currently on Beta 10 or wait until 2018 is fully released in a few weeks as well as using the latest version of HDRP which is currently 4.2.0 (This will give you shader graph 4.2.0 which has the Lit Master node as well as well as some other HDRP Master nodes)
     
  18. adslitw

    adslitw

    Joined:
    Aug 23, 2012
    Posts:
    146
  19. izym

    izym

    Unity Technologies

    Joined:
    Jul 27, 2013
    Posts:
    24
    We're planning to provide support for LWRP simple lighting in Shader Graph, but we don't have an ETA currently.
     
    Hardev and adslitw like this.
  20. Devil_Inside

    Devil_Inside

    Joined:
    Nov 19, 2012
    Posts:
    947
    I need a variation of this for a diffuse sprite. Currently it is impossible to crate a sprite that can receive simple lighting.
     
  21. jtannert17

    jtannert17

    Joined:
    Jun 1, 2017
    Posts:
    8
    @izym Is there any update on this?
     
    kman360 likes this.
  22. Vasonic

    Vasonic

    Joined:
    Dec 6, 2017
    Posts:
    1
    bump
     
    kman360 likes this.
  23. Hardev

    Hardev

    Joined:
    Jun 19, 2017
    Posts:
    2
    I'm also very interested in this. Would be really great to be able to create Simple Lit graphs. Glad to hear it is planned!
     
    kman360 likes this.
  24. kman360

    kman360

    Joined:
    Apr 15, 2014
    Posts:
    2
    any updates?
     
  25. FeedMyData

    FeedMyData

    Joined:
    Oct 19, 2013
    Posts:
    3
    Any ETA?
     
  26. ph_

    ph_

    Joined:
    Sep 5, 2013
    Posts:
    139
    @FeedMyData FYI, I've just released a package on the asset store that gives you just that: a SimpleLit master node.
    In addition, it add more than 30 noises that I felt were missing in ShaderGraph, including Perlin 2D/3D, fractal ...etc.
    ShaderGraph Essentials on the asset store

    Sorry, it's probably not the right channel to do some promotion, but the package does solve your problem :)
     
    Last edited: Apr 26, 2019
  27. GameDevCouple_I

    GameDevCouple_I

    Joined:
    Oct 5, 2013
    Posts:
    2,126
    Looks nice but I am not sure how worthit it is to purchase an asset built on beta tech, considering you dont support 2019 currently yet the 2018.3 api is drastically different and so is its feature set, I think getting this asset will just lead to headaches down the line. I will revisit it once 2019.1 is out of beta and once you support it, but dont take this as unappreciative as it looks like nice work
     
    ph_ likes this.
  28. ph_

    ph_

    Joined:
    Sep 5, 2013
    Posts:
    139
    No offense taken, you have a very valid point ! To be honest when I talked to people, the main thing they were interested in was the noise nodes / bake texture, not the SimpleLit master. Plus Unity will probably release it on its own at some point.
    The 2019+ support was definitely a question I asked myself before releasing the asset; and I did so because I'm confident I can port the noises, and pretty confident I can port the "Bake Texture" feature. I also got an extensive list of features I want to add.
    Thanks for your feedback @GameDevCouple_I :)
     
    GameDevCouple_I likes this.
  29. Brad-Newman

    Brad-Newman

    Joined:
    Feb 7, 2013
    Posts:
    112
    Bump. Want this feature please!
     
  30. ph_

    ph_

    Joined:
    Sep 5, 2013
    Posts:
    139
    @GameDevCouple_I you might be interested to know that ShaderGraph Essentials (Asset store link) now supports 2019.1!
    A few people use it with this version already!
    simple_lit_master.PNG
     
    Last edited: Apr 26, 2019
    phil_lira and Horus_Sungod42 like this.
  31. cirocontinisio

    cirocontinisio

    Unity Technologies

    Joined:
    Jun 20, 2016
    Posts:
    33
    Just wanted to say, amazing job on that little package!

    And yes (quite late on the conversation), it was me. I hope it was useful, at the time. Obviously that API was removed (ShaderGraph was in preview, after all) and now we have the Custom Function Node, which does more or less the same thing without the need to create a custom C# class. The Asset from @ph_ makes really good use of them.

    I'll now add some notes to those old Connect posts to make sure people know they are old workflow.
     
    ph_ likes this.
  32. ph_

    ph_

    Joined:
    Sep 5, 2013
    Posts:
    139
    Thanks! There're still a lot of features I want to add!
    ShaderGraph itself is really nice, thanks for developing it! Of course there are a lot of feature request and possible improvements, but it's already helping a lot of people getting in shader and graphics in general ... and that's really cool!
     
  33. jonny2027

    jonny2027

    Joined:
    Jul 16, 2013
    Posts:
    61
    Any update on this yet?