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. Join us on March 30, 2023, between 5 am & 1 pm EST, in the Performance Profiling Dev Blitz Day 2023 - Q&A forum and Discord where you can connect with our teams behind the Memory and CPU Profilers.
    Dismiss Notice

How to set up the new Water System

Discussion in 'High Definition Render Pipeline' started by Rowlan, Apr 6, 2022.

  1. Rowlan

    Rowlan

    Joined:
    Aug 4, 2016
    Posts:
    3,480
    I've been trying to find out how to set up the new water system that came initially with 2022.2.0a9. It wasn't that straightforward, so I thought I'd make a post for others.

    * Project Settings > Quality > HDRP > Rendering > Water

    s1.png
    * Project Settings > Graphics > HDRP Global Settings > Water Rendering

    s2.png
    * Hierarchy > Water Surface > Ocean

    s4.png

    In case everything is white like it was for me, adjust the Exposure in your Sky and Fog Volume.

    Looks like this then:

    game.jpg
     
  2. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    In case nothing is showing with all those steps, make sure that Water is enabled under
    Graphics > HDRP Global Settings, Frame Settings (Default Values) in the "Rendering" Foldout upload_2022-4-6_10-35-45.png


    Also, for the Water Rendering override, you can just add it in a volume to your scene like any override.
    You don't HAVE to use the default volume profile asset in Graphics > HDRP Global Settings.
     
  3. wm-VR

    wm-VR

    Joined:
    Aug 17, 2014
    Posts:
    123
    Is the water system also compatible with Unitys path-tracer?
     
  4. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    Nope, sorry :)
     
  5. VRS3DGuru

    VRS3DGuru

    Joined:
    Sep 21, 2017
    Posts:
    6
    How do you add this into 2022.1.7f1 manually?
    Is there a specific preview package we can add to start working with it before 2022.2.1 is released?
     
  6. Ad

    Ad

    Joined:
    Aug 16, 2012
    Posts:
    11
    Hello,
    I've followed the above and still have no water rendering.
    You mention Project Settings > Quality > HDRP > Rendering > Water
    There is no option for CPU

    https://imgur.com/a/zGaFwtc

    all other options regarding water are ticked.

    Sys spec : ryzen 5 3600 CPU
    AMD RX480 8GB GPU
    using windows 10 home edtion.

    Any help would be appreciated thanks.
     
  7. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    If you already checked, Frame Settings, HDRP asset, Volume Override (which technically should be enough), you can try two other things.
    • Try reimporting HDRP (Right click on Packages/High Definition RP folder and reimport), sometime some shader can be corrupted and prevent some effect to be working properly
    • Close project, delete library folder and re-open.
     
  8. NewMagic-Studio

    NewMagic-Studio

    Joined:
    Feb 25, 2015
    Posts:
    324
    I am using Unity 2022.2 beta, and doesnt work, i have all water options activated, i create an Water surface object and no water is rendered. I dont have some of the options shown, also can't find anywhere the Volume override mentioned in last post. I reinstalled hdrp as mentioned in last post and that just made the project not work at all, there is not global settings for hdrp and get lot of errors.
     
  9. NewMagic-Studio

    NewMagic-Studio

    Joined:
    Feb 25, 2015
    Posts:
    324
    I removed the project, created a new hdrp project and just activated water system in hdrp global and in quality hdrp, then created a Water surface object of ocean type, pressed play and no water is rendered
     
  10. Marked

    Marked

    Joined:
    Feb 24, 2015
    Posts:
    32
    did you added Water Rendering to your global volume ?

    upload_2022-8-29_8-28-51.png
     
  11. NewMagic-Studio

    NewMagic-Studio

    Joined:
    Feb 25, 2015
    Posts:
    324
    Yes, found the problem some days ago, the problem is that besides that you need to add water as one more volumetric effect ins hdrp settings
     
  12. alias

    alias

    Joined:
    May 14, 2013
    Posts:
    11
    i followed all your steps and i also didnt get a water surface only the icon.

    then i added a global volume to the project, and add the water component checked all the boxes.
    and yes there is now visual water
     
  13. alias

    alias

    Joined:
    May 14, 2013
    Posts:
    11
    anyone knows how too get buoyance on like boats? like they move with the waves?
    i know there is 2d buoyance. but i couldnt anything like this for the new water system.

    which looks really good. with the caustics and underwater settings.
     
  14. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    Depending on which version you are, the WaterSurface script, there's an API to query the projected position of the current water surface at a specific position (basically to make an object stick to the surface).
    After that, it's up to users to create the buoyancy system depending on their needs !
     
  15. alias

    alias

    Joined:
    May 14, 2013
    Posts:
    11
    Depending on which version you are, the WaterSurface script, there's an API to query the projected position of the current water surface at a specific position (basically to make an object stick to the surface).
    After that, it's up to users to create the buoyancy system depending on their needs
    --------------------------------------------------------------------------------------------------------------------------------------------

    Im on 2022.0b4 beta.

    too bad it isnt a physic droppdown option.
    like you have with the 2d Buoyancy
     
  16. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    Then you should be able to query your WaterSurface with this function FindWaterSurfaceHeight()

    Yep, for now it's completely independent on the Physics system.
    This can be revisited in the future but there's still many important work to do on the water system before that.
     
  17. Rowlan

    Rowlan

    Joined:
    Aug 4, 2016
    Posts:
    3,480
    @chap-unity Is there some integration or instruction about how to use rivers with the unity splines?
     
  18. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    Sadly, no. For now water system is not integrated with any other system. You have to feed it custom geometry if you want something specific.
     
  19. shikhrr

    shikhrr

    Joined:
    Nov 19, 2013
    Posts:
    54
    I hope the unity splines package gets integrated into water and terrain systems like unreal. This is important, a lot of users would love that.
     
    graskovi and chap-unity like this.
  20. NightElfik

    NightElfik

    Joined:
    Oct 27, 2014
    Posts:
    22
    Is it expected that water does not work when MSAA is enabled (forward rendering)? I have spent too much time figuring out why water is not rendering and MSAA was the culprit. Is there any way to get water + MSAA? (Unity 2022.2.0b8)
     
  21. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    Hey, sorry about this one. Water is just not compatible with it and right now, it will throw a bunch of errors.
    It has been "fixed" on our side by not being able to enable MSAA if you have water enabled in the HDRP asset (same as raytracing for exemple).

    In the future, maybe a fallback will be made but for now, it's just not supported.

    Edit : This "fix" will be backported to 2022.2 as well.
     
  22. NightElfik

    NightElfik

    Joined:
    Oct 27, 2014
    Posts:
    22
    Thanks for the answer. I am curious what technical limitation causes this? How MSAA interfere with water rendering/simulation?
     
  23. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    It's because the rendering algorithm for water surfaces is only deferred (there's no forward version of it).
    Since MSAA is only compatible with forward rendering.. that settles it.
     
  24. ebaender

    ebaender

    Joined:
    Oct 29, 2020
    Posts:
    79
    Is anybody else experiencing this issue where caustics are rendered as triangles?

    This is in a fresh outdoors template in 2022.2.0f1 with nothing but water and a plane underneath it added, HDRP and water surface are on default settings otherwise.

    upload_2022-12-13_9-49-50.png
     
  25. ebaender

    ebaender

    Joined:
    Oct 29, 2020
    Posts:
    79
    Talked to a Unity dev on Discord about this issue, as expected it's another easily reproducible issue on AMD GPUs.

    Kind of sad that I'm the first to notice something this obvious since the water system has been in development for some time. This is a pretty tame case since this isn't a crucial feature in an LTS release for once, but still another clear indicator that Unity simply isn't developed or tested on desktop AMD cards.

    At this point not buying into Nvidia has become an actual liability, and I'm feeling more and more like I no longer have a choice unless I'm willing to put up with tons of downtime writing bug reports, looking for workarounds, and potentially missing a deadline over undiscovered AMD-specific issues that may or may not be fixed in time.
     
    Last edited: Dec 13, 2022
    shikhrr and impheris like this.
  26. impheris

    impheris

    Joined:
    Dec 30, 2009
    Posts:
    911
    Wow that is really bad
     
    unity_8p6oRXXqiWbRTQ likes this.
  27. Patrudoizero

    Patrudoizero

    Joined:
    Nov 30, 2018
    Posts:
    10
    It works great in Game mode and Editor, but the water does not show in build.
     
  28. jasonrobertnelson

    jasonrobertnelson

    Joined:
    Feb 2, 2021
    Posts:
    2
    What does it mean when "Water" is not under these settings. I've been trying to figure this out for weeks.
     
  29. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    If you can't see "water" under the HDRP default frame settings or "Water Rendering" in the override list, it just means that you are using an older version of Unity where Water is not supported yet.

    For reference Water is available starting from 2022.2 with a limited amount of features. (And we only backports bugs there)
    And the development continue in 2023.1 alphas with more possibilities added.
     
  30. stojic

    stojic

    Joined:
    Feb 11, 2016
    Posts:
    3
    How did you make reflections work , mine only reflects sky maybe
     
  31. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    563
    If by reflection you mean Screen Space Reflection, then since water is considered a transparent you need to activate SSR on transparent for it to work correctly. There's 3 things to do:
    • Check the frame settings
    • Check the setting on the HDRP asset
    • Enable it in the Screen Space Reflection override.

    Keep in mind that SSR on transparent have some limitations like, PBR accumulation fallbacks to approximation, reflection is always smooth, no sky... etc