Comments (20)
I don't believe I was able to reliably reproduce it before, but I could with your scene.
Just to confirm the issue, is it only related to physics objects? Applying interpolation to the rigid body to the repro seems to be a pretty good workaround.
from crest.
Flow does cause pulsing artefacts. Is that what you are seeing? I will need a video to understand if it is not too much trouble.
from crest.
Flow does cause pulsing artefacts. Is that what you are seeing? I will need a video to understand if it is not too much trouble.
I will get some video.
from crest.
Flow does cause pulsing artefacts. Is that what you are seeing? I will need a video to understand if it is not too much trouble.
Videos are low res and broken up to support upload.
This first one is the scene more or less following the repro steps:
2023-06-24.07-53-40_2.mp4
2023-06-24.07-53-40_3.mp4
This one is with an actual physics objects / boat stuff happening.
2023-06-24.07-53-40_5.mp4
This is something new I am pretty sure, it did not used to do this.
from crest.
Thanks. I wasn't able to reproduce it myself. Not sure what it could be.
Have you changed any of the simulation settings files (Foam or Dynamic Waves)? There is a simulation frequency setting for both that may help.
What is your frame rate?
from crest.
The framerate for these in game is ~60FPS. I believe the framerate in the example scene is unbound so it was probably ~300fps. The only settings I changed in the boatwakes scene was zeroing out the spectrum for the waves to make it easier to see and adding whirlpools on empty game objects where I moved around and changed the radius.
I was able to verify this is some sort of regression, I ran the same test with the BoatWakes scene in crest version 4.15 (same unity version) and everything is nice and smooth as it gets sucked down into the whirlpools. It seems reproducible on multiple computers with 4.17.
Here is some more video comparing the 2 versions. As far as I can tell both of these have the same settings and are unaltered from the branch, with the exception of the spectrum and addition of whirlpools. The only difference I noticed is that the whirlpools do not appear until playback has started in 4.15
4.15 (smooth):
415.mp4
417.mp4
from crest.
There is a simulation frequency setting for both that may help.
For both 4.15 and 4.17 BoatWake scenes the simulation frequency is:
Increasing this value in 4.17 has no effect (probably undesirable performance impacts). Decreasing the value seems to make the problem much much worse. Maybe that can help reproduce it. Decreasing this value on 4.15 does degrade visuals but the overall movement is still smooth.
The foam simulation rate is 30 on both and has similar effects as described above.
from crest.
I'm looking at this more to see if I can help pinpoint the cause and provide as much info as I can.
It does not seem to be caused by changes to the following:
- Whirlpool.cs
- SphereWaterInteraction.cs
- OceanRenderer.cs
- LodDataMgrFlow
It may be related to changes to (the 2 versions are pretty incompatible so its hard to tell):
- LodDataMgrDynWaves.cs
- LodDataMgrPersistent.cs
- RegisterLodDataInput
Problems do not occur if "Create Flow Sim" is off
Problems do not occur if "Create Flow" is off on Whirlpool
Problems do not occur when passing through a CrestRegisterFlowInput
Problems still occur when "Flow" is disabled on the shader (which is interesting)
Problems still occur when zoomed out (and LOD still visible)
It does not seem related to foam (just easier to see). It still happens when Foam is off on the shader: The image below is just a visual reference, shaking is hard to see even on video.
If I manually disable foam vs sphere interaction behavior the problems still occur if only one is enabled which tells me its definitely related to flow, not foam or sphere interactions.
I am seeing a fundamental difference in wake foam between versions as well, while not really a concern it may indicate the cause.
from crest.
Thanks. I was able to reproduce it only intermittently. Some machines were harder than others. I was able to reproduce a more subtle jitter reliably 4.17 and 4.15. Not sure if that means 4.15 will reproduce the less subtle case or not.
Are you able to reproduce the more noticeable jitter case (like the red plane video) reliably?
I agree that it may have something to do with SWI and flow together. Since SWI queries flow I think it has to do with queries. I will see if I can get a reliably reproducible together at some point.
from crest.
Thanks. I was able to reproduce it only intermittently. Some machines were harder than others. I was able to reproduce a more subtle jitter reliably 4.17 and 4.15. Not sure if that means 4.15 will reproduce the less subtle case or not.
That is good news, thanks. I'm not concerned with 4.15 except as a comparison. 4.17 fixed a lot of other issues so I'm probably going to stick with it and continue updating as needed. I think there is subtle jitter in 4.15 in general, but not as extreme (that I noticed.) and it did not appear in any game builds.
Are you able to reproduce the more noticeable jitter case (like the red plane video) reliably?
Yes. Its 100% of the time in the current build with 4.17. The BoatWake scenes is about 90% of the time. I am happy to try out any available fixes / branches in the future and / or get it thoroughly tested.
I agree that it may have something to do with SWI and flow together. Since SWI queries flow I think it has to do with queries. I will see if I can get a reliably reproducible together at some point.
👍
from crest.
I'm not concerned with 4.15 except as a comparison
Yeah, it is more about getting a more reproducible case. I am not having much luck and starting to doubt previous findings.
For both 4.15 and 4.17 BoatWake scenes the simulation frequency is:
Is that Dynamic Waves? Foam also has a simulation frequency. Have you tried increasing it to 120 too? Everything seems related to simulation frequency so far for me. This will be especially the case at high speeds.
from crest.
Is that Dynamic Waves? Foam also has a simulation frequency. Have you tried increasing it to 120 too? Everything seems related to simulation frequency so far for me. This will be especially the case at high speeds.
I attempted to adjust both of the sliders related to simulation frequency. They seemed to have little affect on the jitter. The only time the jitter ever stopped was when flow was turned off in some form.
from crest.
I looked at this some more and I noticed something odd and something else useful.
What was odd was that after closing the crest project and opening it later (today), it was much harder to see any jitter. I had to play around with a bit to even see a hint of what I saw before.
I noticed when I was trying to figure out where there jitter went that by removing the camera from the wake rig, the jitter seemed less, so I used a free moving camera and placed some spheres around a new whirlpool and everything seemed mostly fine. So I checked in game and it does seem related to movement in some way. It does not occur when boats are kinematic. Could be related to velocity.
I was able to narrow this down a bit more specific. I created a sphere with a foam override that also has a CrestSimpleFloatingObject on it. I placed it in the BoatWake scene and it seems fine spinning around the flow of the whirlpool. I placed an identical object in game and it freaks out like the boat does. So now I can only assume there is something different. A settings somewhere... something that changed from 4.15 -> 4.17
I copied the entire ocean from BoatWake into the problem scene and the issue still occurs. I am going to have to start picking things apart to see when the problem stops I guess.
The more I examine this the less it seems to make sense. I added a sphere with foam override at the same time the boat was having issues and it seemed to make things smoother. Removing the sphere seemed to make it worse, seems to indicate a timing issue to me or some sort of rendering out of order. The camera in the demo scene is using Update to move the camera around, my camera is using LateUpdate. Changing camera to use Update (which is not really an option) does not make it smooth however copying the Demo camera into the scene seems to be slightly smoother for some reason. It feels like I am chasing the symptoms of a different timing issue upstream related to changes from 4.15 -> 4.17 as I cannot pinpoint any one thing causing the problem and it seems unrelated to any configuration of the Ocean given that the example one has the same issues. To confuse matters even more I am no longer able to reproduce jitter in the boat wakes scene even though I was able to this morning and previously.
from crest.
If you add a sphere to the demo scene and hardcode the framerate to not be unbound it seems like it is a lot more reproducible and looks very close to what I am seeing in game. In game I have vsync on and get around 60fps so its not exactly the same.
QualitySettings.vSyncCount = 0;
Application.targetFrameRate = 50
Setting the framerate somewhere between 30-60 seems to display the issue. It does not always show though... which is strange. Sometimes I had to change the framerate from 30 to 50 then let it compile then hit play and it happens, other times I set it to 30 and hit play and it seems smooth, but it is definitely easier to happen. It may also help to follow the sphere with the camera as it moves. Hardcoding this behavior in 4.15 does not seem to cause this problem.
Hope this helps!
from crest.
@daleeidd Were you able to reproduce this?
from crest.
Here is a repro scene modifying the BoatWakes scene. Move the camera around and follow the cube. Its a bit goofy setup, but it took a while to repro in latest.
from crest.
I don't believe I was able to reliably reproduce it before, but I could with your scene.
Just to confirm the issue, is it only related to physics objects? Applying interpolation to the rigid body to the repro seems to be a pretty good workaround.
Excellent, glad you are able to see the issue now.
It does seem directly related to being tied to a physics object and flow/foam. PhysX Interpolation is not an option and does not resolve the problems at runtime or in my project. Override foam on "static" objects or transform based movement seems to have less issue.
One bizarre note about this I have been seeing off an on is that solutions can be inconsistent, for example interpolation may momentarily appear to solve the issue the same way that reducing the flow speed or changing some other setting will, but it quickly goes back to vibration foam. Similar things happen when adding new foam to the scene or removing them while attempting to troubleshoot, almost seems like it changes the timing for the better momentarily, couldn't say for sure.
I would say its some sort of timing / update issue that is revealed by FixedUpdate behavior of some sort. Something in the execution order is moving the foam/flow back to where it was or predicting its location erroneously.
from crest.
Any updates on this?
from crest.
No. I noticed Follow Horizontal Motion is disabled for the foam input. Does enabling change anything?
from crest.
No. I noticed Follow Horizontal Motion is disabled for the foam input. Does enabling change anything?
It does not appear to have an affect.
from crest.
Related Issues (20)
- Local / movable spectrums or crest shapes HOT 3
- Pressing the Windows Key in the editor disables underwater rendering HOT 3
- Wake / foam artifacts when moving the camera quickly HOT 11
- Delayed LOD / tile enabling when using large clipping areas HOT 5
- Depth Cache not populated - Exported Image is Black HOT 8
- Water interaction is not visible when moving camera away from the sea level HOT 1
- Underwater broken with XR multi-pass rendering HOT 1
- No caustics, no shadow data and/or constant shadowing on iOS
- Error of Does not exist some Classes. HOT 1
- Sporadic gaps / precision errors in tiles. HOT 36
- SphereWaterInteraction and RegisterDynamicWavesInput do not work correctly inside a flow area HOT 11
- Activating flow in the material when oceanrenderer is running does only work in editor HOT 2
- FindObjectsSortMode HOT 3
- Enable Shader API does not function without changing underwater appearance HOT 20
- Enable Shader API causes artifacts HOT 4
- Planar Reflections issue with non-standard shaders using transparency HOT 13
- Premature tile culling during extreme camera maneuvers above the ocean HOT 1
- Portal feature broken with Unity Recorder 360 View
- Directional lights that are not active on any layer change the color of subsurface scattering HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from crest.