Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Decal normal blend

Discussion in 'Shader Graph' started by juanpatrickpds, Oct 5, 2023 at 6:16 AM.

  1. juanpatrickpds

    juanpatrickpds

    Joined:
    May 27, 2021
    Posts:
    3
    I'm having this annoying issue for like a week and I just don't know how to fix it, I made a water shader and right now I'm trying to convert it to use as a decal, but the "affect normal" property just override the normals below the decal, there's any way to just multiply de normals or just mask where I want them to affect

     
  2. BenCloward

    BenCloward

    Unity Technologies

    Joined:
    Jul 15, 2021
    Posts:
    89
    Is this in URP or HDRP? And what version of Unity?
     
  3. juanpatrickpds

    juanpatrickpds

    Joined:
    May 27, 2021
    Posts:
    3
    It's HDRP, unity 2021.3.17f1

    Also it's an awesome plot being helped by you Ben because I started to learn about Shaders 1 month ago watching your videos, ty so much for your content on Youtube, you helped me A LOT

    This is the shader today
    upload_2023-10-5_14-49-12.png
     
  4. BenCloward

    BenCloward

    Unity Technologies

    Joined:
    Jul 15, 2021
    Posts:
    89
    In order to get the effect you're looking for, you need to open the HD Render Pipeline Asset that your project is using, find the Decal section in the settings, and turn on Additive Normal Blending.

    upload_2023-10-5_17-13-1.png

    For some reason, in the testing I did with it, it wasn't working in 2021LTS and I had to update my project to 2022LTS in order for the feature to work as expected. I'm not sure why that is, but if you also have that problem, you're welcome to post about it in the HDRP forum.
     
  5. juanpatrickpds

    juanpatrickpds

    Joined:
    May 27, 2021
    Posts:
    3
    That make sense, I tried this before but doesn't worked well, I upgraded to 2022.3.2f1 and now it's working as expected, thank you so much Ben

    upload_2023-10-5_23-14-6.png