Announcement

Collapse
No announcement yet.

Physical Water Surface

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Originally posted by Theokoles View Post

    Actually, the Infinite Ocean System should do a fine job of creating the impression of an infinite ocean. The water plane is moved and scaled with the camera so that the horizon is always very far away. Did you enable the Follow Camera option (see here)?
    This is the default phsyical water pasted into the default beach cliffs scene.

    Also, the beach cliffs scene use a planar reflection, but the material isn't compatible with forward rendering. I saw a mention of of improving existing water shaders with the physical water movement, but I also need the distance field masking. Is this possible?
    Attached Files

    Comment


      Ok, so turns out that planar reflections was super easy (just tick the box in the material).

      Click image for larger version

Name:	Capture.jpg
Views:	73
Size:	172.8 KB
ID:	1664240

      I'm still interested in a way of fake extending the ocean all the way up to the skybox.

      Comment


        Originally posted by roberteker View Post

        I'm still interested in a way of fake extending the ocean all the way up to the skybox.
        Please try to increase the HeightZoomFactor parameter of the WaterPlane Blueprint. Changing this parameter from 1 to 10 will increase the size of the water plane by a factor of 10. After increasing this value you should have a look at the running game in Wireframe mode to check if the mesh size of the water plane is still appropriate.

        Comment


          Originally posted by Theokoles View Post

          Please try to increase the HeightZoomFactor parameter of the WaterPlane Blueprint. Changing this parameter from 1 to 10 will increase the size of the water plane by a factor of 10. After increasing this value you should have a look at the running game in Wireframe mode to check if the mesh size of the water plane is still appropriate.
          Thanks, that helped, but it made the water immediately around the boat very coarsely tesselated using any value above 5.

          I'm using quite calm waters right now, so it works for me, but it seems that unless I missed something, I wouldn't want to try this with larger waves.

          Comment


            Originally posted by roberteker View Post

            Thanks, that helped, but it made the water immediately around the boat very coarsely tesselated using any value above 5.

            I'm using quite calm waters right now, so it works for me, but it seems that unless I missed something, I wouldn't want to try this with larger waves.
            Please have a look at the water plane mesh, it has an area with higher triangle count in the middle. The camera is always above this area where the triangle count is high, resulting in good looking water under normal conditions.
            If you set HeightZoomFactor to 5, this means that the water plane mesh is scaled up by a factor of 5. As a result, the triangle size in the middle of the water plane becomes too large, resulting in the "coarsly tesselated" look that you describe.
            To fix this, you need to modify the water plane mesh or create your own water plane mesh where the triangle size in the middle of the water plane is five times smaller than in the original water plane mesh that comes with Physical Water Surface. Then the water will look normal again (with HeightZoomFactor set to 5).

            Comment


              Originally posted by Theokoles View Post

              Please have a look at the water plane mesh, it has an area with higher triangle count in the middle. The camera is always above this area where the triangle count is high, resulting in good looking water under normal conditions.
              If you set HeightZoomFactor to 5, this means that the water plane mesh is scaled up by a factor of 5. As a result, the triangle size in the middle of the water plane becomes too large, resulting in the "coarsly tesselated" look that you describe.
              To fix this, you need to modify the water plane mesh or create your own water plane mesh where the triangle size in the middle of the water plane is five times smaller than in the original water plane mesh that comes with Physical Water Surface. Then the water will look normal again (with HeightZoomFactor set to 5).
              Thanks, I will have a go at this when I get the time!

              Comment


                Originally posted by roberteker View Post

                Thanks, I will have a go at this when I get the time!
                Let me know if you have more questions!
                I've used Blender to make the water plane mesh. Just create a plane and then use the Subdivide tool to add more faces in the middle of the plane.

                Comment


                  Physical Water Surface - Quick Tips #3: Events for entering/leaving the water

                  Did you know that Physical Water Surface provides events in the Buoyancy Blueprint that are triggered when an objects enters or leaves the water?
                  This can be very useful for performance optimizations in case you have a large number of objects and only some of them are actually floating in the water. With this events you can easily disable any Blueprint code that doesn't need to run when an object is not floating.

                  Click image for larger version

Name:	events.PNG
Views:	81
Size:	20.2 KB
ID:	1673114

                  Comment


                    Quick Question on something, i have a world with a complex ship object that the player stays on for most of the level, having the ship move at cruising speed can cause problems with performance and player issues.
                    A method that seems to work well is program the ocean and world to move by using level sequencer or Matinee. I created a cube that i attached the ocean and sky too, and in the editor it seemed to work fine. But when playing the level, the ocean does nothing and stands still, is there something im missing?
                    Any help would be appreciated!
                    Click image for larger version

Name:	world.PNG
Views:	105
Size:	20.0 KB
ID:	1679508

                    Comment


                      Originally posted by Dreamcastgamer View Post
                      Quick Question on something, i have a world with a complex ship object that the player stays on for most of the level, having the ship move at cruising speed can cause problems with performance and player issues.
                      A method that seems to work well is program the ocean and world to move by using level sequencer or Matinee. I created a cube that i attached the ocean and sky too, and in the editor it seemed to work fine. But when playing the level, the ocean does nothing and stands still, is there something im missing?
                      Any help would be appreciated!
                      Click image for larger version

Name:	world.PNG
Views:	105
Size:	20.0 KB
ID:	1679508
                      First I would like to recommend to you to investigate with the UE4 profiling tools if you can find out the reason for the performance issues when moving the ship at high speed. I've never encountered this, and fixing the performance issue might prove to be easier than to move the ocean and level as you suggest.

                      If you want to move the ocean and level, please consider the following:

                      In the Water material you can see that the AbsoluteWorldPosition node is used for the coordinates. This means that if you move the water plane, it appears as if the water (waves and textures) don't move and remain at the same location. To make the water actually appear to be moving with the world, you can try to replace the AbsoluteWorldPosition node with a Panner. Please note that in some of the Material Functions the AbsoluteWorldPosition node is also used, it needs to be replaced everywhere.

                      Please also have a look into the EventGraph of the WaterPlane Blueprint. You will find the Blueprint code responsible for the InfiniteOceanSystem. If enabled, the InfiniteOceanSystem could cause movements of the water place that are not desired in your case.

                      Comment


                        Originally posted by Theokoles View Post

                        First I would like to recommend to you to investigate with the UE4 profiling tools if you can find out the reason for the performance issues when moving the ship at high speed. I've never encountered this, and fixing the performance issue might prove to be easier than to move the ocean and level as you suggest.

                        If you want to move the ocean and level, please consider the following:

                        In the Water material you can see that the AbsoluteWorldPosition node is used for the coordinates. This means that if you move the water plane, it appears as if the water (waves and textures) don't move and remain at the same location. To make the water actually appear to be moving with the world, you can try to replace the AbsoluteWorldPosition node with a Panner. Please note that in some of the Material Functions the AbsoluteWorldPosition node is also used, it needs to be replaced everywhere.

                        Please also have a look into the EventGraph of the WaterPlane Blueprint. You will find the Blueprint code responsible for the InfiniteOceanSystem. If enabled, the InfiniteOceanSystem could cause movements of the water place that are not desired in your case.
                        Will do, thanks a bunch for giving some ideas!

                        Will let everyone know what solution i ended up going with to help others in the future.

                        Comment


                          Does this work with Tropical Ocean Tool? I would like to keep the underwater, auto beach material wetness effect, and automatic landscape detection for proper wave generation if possible. Since 4.23 it includes infinite ocean too.
                          LEGENDS of EPICA [Twitter] [Facebook] [YouTube] [Vimeo]

                          Comment


                            Originally posted by unit23 View Post
                            Does this work with Tropical Ocean Tool? I would like to keep the underwater, auto beach material wetness effect, and automatic landscape detection for proper wave generation if possible. Since 4.23 it includes infinite ocean too.
                            Some manual work will required for sure to make it work together. I don't have access to Tropical Ocean Tool, so I can't say exactly how much work it would be.
                            From this tutorial you can get an idea how Physical Water Surface can be combined with other water materials. It will probably be a similar process to use it with Tropical Ocean Tool.

                            Comment


                              Originally posted by Theokoles View Post
                              Some manual work..
                              Hi Theokoles, do you maybe have some suggestion on how to achieve something similar to this?

                              Click image for larger version  Name:	dummy.jpg Views:	0 Size:	109.9 KB ID:	1691414
                              Last edited by unit23; 11-26-2019, 12:08 PM.
                              LEGENDS of EPICA [Twitter] [Facebook] [YouTube] [Vimeo]

                              Comment


                                Originally posted by Theokoles View Post
                                Compatibility with Orbit Weather and Seasons
                                (UE 4.12 and higher)

                                I've collaborated with the developer of Orbit Weather and Seasons to make his weather system and Physical Water Surface compatible. With this compatibility, changing the cloud density will automatically also trigger a sea state transition if you use both systems together. For detailed information, see this wiki page.
                                The page does not exist, can you point me to a guide, or briefly describe steps, thanks.
                                LEGENDS of EPICA [Twitter] [Facebook] [YouTube] [Vimeo]

                                Comment

                                Working...
                                X