Search Unity

  1. If you have experience with import & exporting custom (.unitypackage) packages, please help complete a survey (open until May 15, 2024).
    Dismiss Notice
  2. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice

HDRP decal not showing in standalone build?

Discussion in 'High Definition Render Pipeline' started by Deadcow_, Apr 23, 2019.

  1. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    As shown on this screenshots, we use decals for paintings on walls in this case. In standalone build decals are just missing. Not just this one, all of them.

    Windows x64 Standalone build
    Unity 2018.3.13
    HDRP 4.10.0p
    ILCPP on and off

    What may cause this?

    2019-04-23_16-29-26.png 2019-04-23_16-35-24.png 2019-04-23_16-35-41.png
     
    XCO likes this.
  2. Team6Developers

    Team6Developers

    Joined:
    Nov 19, 2018
    Posts:
    12
    We're also experiencing this issue since our upgrade to 2019.1.0f2, verified broken in standalone builds for PC (Steam) Switch, XboxOne and PS4. A clean project including HDRP with no modified settings has the same results: No decals in standalone builds.

    The error we're getting on all platforms:
    RenderingCommandBuffer: invalid pass index 4 in DrawMeshInstanced
     
  3. Team6Developers

    Team6Developers

    Joined:
    Nov 19, 2018
    Posts:
    12
    Fixed it by setting "perChannelMask" to true in the pipeline settings (translated in editor to Metal and Ambient Occlusion Properties). This also resolved the "invalid pass index 4 in DrawMeshInstanced" error. Sounds like a bug, but oh well, at least decals work.

    I hope this works for you too, best of luck.
     
    edwiz7 likes this.
  4. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    Did you mean this one?
    2019-04-25_09-21-46.png


    Just tried it, makes no difference :( I also tried to set 2048 or 8192 Atlas size and increase Draw distance just in case. No luck :(

    Did you changed some other settings maybe? Terrible time to find out this one. We want to arrange some showcase TODAY :mad:
     
  5. Team6Developers

    Team6Developers

    Joined:
    Nov 19, 2018
    Posts:
    12
    Thats the one yes, unfortunately that's the only change. You could try upgrading to 2019 and use hdrp 5, copying your project and using the unity HUB allows you to keep both projects and unity versions.

    The only change we had to make was replacing all post processing stack v2 objects with HDRP volumes, besides that no new issues.

    Best of luck! Lets hope for an official Unity response on the matter.
     
  6. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    We tried to upgrade, but we have one custom post process effect and figured out HDRP PP not allows to cave custom ones yet. But I'll try again just to check if decals will work. Thanks
     
  7. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    I'm really hope to get the answer from Unity Team, guys? :oops:
     
  8. SebLagarde

    SebLagarde

    Unity Technologies

    Joined:
    Dec 30, 2015
    Posts:
    935
    Hi,

    when a shader isn't available in the player it mean it have been stripped.
    Now the question is to know why. There could be a bug, or you can have forget to check or uncheck an option that is required. For example for the Metal and AO, this is required if you have decal that must affect AO or metal.
    See all settings here: https://github.com/Unity-Technologies/ScriptableRenderPipeline/wiki/HDRP-Asset
    Also in 2019.1 you have a help box that explain what is removing shader variant in HDRP asset inspector.

    I will let our QA know about the issue , see if he can repro, but we don't produce fix for 2018.3 currently (HDRP is in preview and have change a lot in 2019.1, and our QA effort is making 19.1 more stable.
     
    Deadcow_ likes this.
  9. Remy_Unity

    Remy_Unity

    Unity Technologies

    Joined:
    Oct 3, 2017
    Posts:
    704
    Hi. There is indeed an issue with the decals, and more specifically the decal projector. Thanks for reporting.
    While you're waiting for a fix, you can (if possible) switch to using mesh decals : simply apply the decal material on a mesh object (a quad for example), and place it a bit over the surface you want it to be applied on.
     
    Deadcow_ likes this.
  10. SebLagarde

    SebLagarde

    Unity Technologies

    Joined:
    Dec 30, 2015
    Posts:
    935
    We found the root cause of the issue. Shader are stripped and cause projector material to be in different order causing rendering issue. Thanks for the report. Fix will be available in 5.14 publish next week.
     
    Deadcow_ likes this.
  11. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    We have a bunch of problems with 2019.1 upgrade and we're still on 18.3, for now we'll try to swap decals with quads where possible. Thanks!
     
  12. SebLagarde

    SebLagarde

    Unity Technologies

    Joined:
    Dec 30, 2015
    Posts:
    935
  13. JamieD64

    JamieD64

    Joined:
    Mar 13, 2018
    Posts:
    5
    Hi, I am experiencing the same issue. Is this fix being merged into a release this week to go up on the Unity Downloads page or will I need to grab it from GitHub? I am little hesitant to go poking around in the source.

    Cheers!
     
  14. JamieD64

    JamieD64

    Joined:
    Mar 13, 2018
    Posts:
    5
  15. FGallorini

    FGallorini

    Joined:
    Aug 2, 2018
    Posts:
    28
    No i'm waiting to
     
  16. ahmet_unity826

    ahmet_unity826

    Joined:
    Dec 28, 2018
    Posts:
    2
    Unity 2109.3.0a7 with HDRP 6.5.2 can not render the decals in standalone. I think some newer version of HDRP fixes the problem but that version has other issues with automated building so we are also waiting for a more stable build.
     
    Last edited: Jul 24, 2019
  17. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    Decals still not working. Well they are working but do not respect drawing distance setting now. Latest HDRP 6.9.0 and Unity 2019.2.2f1 ! They just appear when you are like 5 units aways from them !
     
  18. Remy_Unity

    Remy_Unity

    Unity Technologies

    Joined:
    Oct 3, 2017
    Posts:
    704
    I was not able to reproduce this issue (with a simple scene tough) using Unity 2019.3.0a12 and HDRP 7.0.1
     
  19. MA-Rob

    MA-Rob

    Joined:
    Sep 10, 2014
    Posts:
    85
    Having the same issue, decals never work in standalone even when the shaders are included. 2019.3.0a11 and HDRP 7.0.1
     
    olavrv likes this.
  20. olavrv

    olavrv

    Joined:
    May 26, 2015
    Posts:
    515
    Created en empty project with HDRP 7.1.x 20. September, Unity 2019.3.0b4. Added a sphere with a decal projector onto it. Works in editor, no decal in build. Windows 10 x64
     
  21. Remy_Unity

    Remy_Unity

    Unity Technologies

    Joined:
    Oct 3, 2017
    Posts:
    704
    We were able to reproduce the issue and an fix is on it's way. It should land in the next package release (7.1.3).

    It was something tied to the shader stripping.
     
    olavrv likes this.
  22. olavrv

    olavrv

    Joined:
    May 26, 2015
    Posts:
    515
    Fantastic news!
     
  23. nehvaleem

    nehvaleem

    Joined:
    Dec 13, 2012
    Posts:
    440
    Do you have an ETA for 7.1.3?
     
  24. olavrv

    olavrv

    Joined:
    May 26, 2015
    Posts:
    515
    It is available on git. We have tested it and it works fine now!
     
    nehvaleem likes this.
  25. mnenad

    mnenad

    Joined:
    Dec 7, 2015
    Posts:
    18
    Just to clearify: I have Unity 2019.2.5f1 installed (latest stabile Unity Version for PC and Mac) and latest Version of HDRP. I get decals working in the Editor Window, also in the Camera View of the Scene - but unfortunately no decals show up in Game View of the Unity Editor. Also the builds do not include decals (I expected this tho).

    Views Image: https://ibb.co/V259jc9

    Decals Projector Image: https://ibb.co/dMZ25CJ

    I'm also using the Cinemachine Asset. If tick the "FullScreen Passthrough" option in the Camera Component Settings decals are rendered in Game View. But ofc this is not a suitable option.

    Camera Settings Image: https://ibb.co/G28rKBN

    I'm curious if I'm having a thread (bug) related problem or my settings are not set up correctly.
    I have all decal options enabled and set up in my HDRP Asset settings as well...

    Hope for an answer @Remy_Unity
    Thank you
     
  26. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    Strange, seemingly 7.1.3 was released just a few days ago. I just tried to import it in our project and... decals are not working! :(
    So my current setup: 2019.3.0b10? HDRP7.1.3 (installed manually, not with package manager). Is there something we can do about it now? Almost 7 months past since this problem is present :eek:
     
  27. FastKillteam1

    FastKillteam1

    Joined:
    Sep 20, 2017
    Posts:
    50
    same issue here... decals work in editor, but not in playmode or builds
     
  28. Blinkq

    Blinkq

    Joined:
    Apr 19, 2015
    Posts:
    21
    have another issue with decals.
    After updating HDRP from 7.1.2(package) to 7.2.0(git).
    Faced really strange issue.
    upload_2019-11-11_14-5-31.png
    after editing any decal variable(size, fadeDistance), it leaves copy, and I cant find that copy and remove it.
    upload_2019-11-11_14-7-4.png
     
  29. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    Guys? I'm really hoping to hear from unity devs about this issue :rolleyes:
     
  30. FastKillteam1

    FastKillteam1

    Joined:
    Sep 20, 2017
    Posts:
    50
    I managed to fix the issue in my project by setting decals to their own layer, and ensuring only one camera renders that layer, hope this helps someone
     
  31. mnenad

    mnenad

    Joined:
    Dec 7, 2015
    Posts:
    18
    I did the same, but I don't see this as a long term solution for my whole project so I agree with @Deadcow_ that this needs to be fixed by some unity devs. thank you
     
  32. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    Do you guys also see no updates for HRDP in package manager? In 2019.3 HDRP 7.1.1 is the only option. There is lots of fixes from 7.1.1 to 7.1.5, I wonder why they are not present in UPM
     
  33. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    I successfully installed 7.1.5. It is visible !
    Maybe try to clear cache in Roaming/Unity.... folder !?
     
  34. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    2,688
    Are you using staging packages?
     
  35. WI_Spas

    WI_Spas

    Joined:
    May 11, 2018
    Posts:
    9
    Experiencing a similar issue, decals don't appear to update until you press Play sometimes, a guaranteed way to make it happen is by changing the material on a decal and moving it, the version with the previous material appears to be "baked" onto the position, even if you move the decal. this happened after we updated to 7.1.5, issue wasn't present in 7.1.2
     
    Blinkq likes this.
  36. Deadcow_

    Deadcow_

    Joined:
    Mar 13, 2014
    Posts:
    135
    I just noticed this line in manifest.json
    upload_2019-11-20_16-16-46.png
    I removed it and now I see tons of updates in UPM :rolleyes: I have no idea how that happened.
    What are those staging packages?
     
    Blinkq likes this.
  37. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    2,688
    Storage for early versions of first packages iteration just for separation early versions from something stable
     
  38. Velo222

    Velo222

    Joined:
    Apr 29, 2012
    Posts:
    1,437
    If your decals are not showing up in the Game view, but they do in the Scene view, this might be caused if you're using more than one camera with HDRP. For some reason the decals stop working if you don't tell all of your cameras to render the layer the decals are on. Unity should be aware of it now.

    There's another thread about this: https://forum.unity.com/threads/decal-problem-in-hdrp.740945/#post-5121548
     
  39. Alaiing

    Alaiing

    Joined:
    Nov 17, 2012
    Posts:
    15
    Hi!
    I'm having the same issue here. I'd like to add that if I disable the decal projector by script, the decal snaps to position (0,0,0) and stays there forever.
    Hope we can find a solution for this.

    Edit: I'm using Unity 2019.3.0f6 with HDRP package 7.1.8
     
  40. hertz-rat

    hertz-rat

    Joined:
    Nov 3, 2019
    Posts:
    71
    I think I am seeing a similar issue, except with materials (or at least, my character materials). I made a thread here: https://forum.unity.com/threads/shadowed-parts-of-characters-are-gray.819990/
     
  41. CohercitionDev

    CohercitionDev

    Joined:
    Aug 2, 2015
    Posts:
    5
    HI
    I've fixed it :

    - In graphics Setting Set : Strip unused in Instancing Variant.

    Decal go back in Build

    I hope that help you
     
    OMGOMGXAXA and olavrv like this.
  42. Deleted User

    Deleted User

    Guest

    I've spent couple hours seeking for source of issue (Unity 2021.1.15f1, HDRP 11.0.0), in my case i had two cameras rendering different layers, but that's doesn't matter.

    - Solution for me was to enable "Custom Frame Settings", then to disable "Decal layers" on both cameras. ALSO, make sure that in project settings in graphics "Instancing Variants" is NOT set to "Strip All"

    (If "Decal layers" is not clickable for you, try to enable Rendering/Decals/Layers in HDRP settings asset)
     
    Last edited by a moderator: Aug 17, 2021