Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  stutter move
#11
Just to try and understand what you're trying to do: the idea is to have a full screen fluid simulation that can be controlled using the phone's movement, is this right?

If so, a much simpler approach is to keep the container static and just set the gravity vector to point in the same direction reported by the phone.


Back to the original problem presented:

Quote:Here with that code that changes the value once in Update loop:

Changing the angular velocity once will have no effect at all. You need to update it every frame, otherwise it is assumed to be zero for a kinematic rigidbody.

Quote:In the next video, I'm modifying the angular velocity of the rigidbody with Is kinematic unchecked. As you could see, the fluid looks a bit behind the container but at least there is no stutter bug.

Ideally, you'd subscribe to the solver's OnBeginStep event, and modify the rigidbody velocity there, before fluid simulation takes place. That would prevent the fluid from lagging behind the rigidbody (otherwise there's a 1 frame delay introduced).
Reply


Messages In This Thread
stutter move - by julienrobert - 22-09-2020, 03:29 AM
RE: stutter move - by josemendez - 22-09-2020, 07:12 AM
RE: stutter move - by julienrobert - 22-09-2020, 01:01 PM
RE: stutter move - by josemendez - 22-09-2020, 01:06 PM
RE: stutter move - by julienrobert - 22-09-2020, 02:06 PM
RE: stutter move - by josemendez - 22-09-2020, 02:12 PM
RE: stutter move - by julienrobert - 22-09-2020, 02:57 PM
RE: stutter move - by josemendez - 22-09-2020, 03:03 PM
RE: stutter move - by julienrobert - 22-09-2020, 03:11 PM
RE: stutter move - by julienrobert - 23-09-2020, 02:20 PM
RE: stutter move - by josemendez - 23-09-2020, 02:52 PM
RE: stutter move - by julienrobert - 23-09-2020, 03:18 PM
RE: stutter move - by josemendez - 23-09-2020, 03:23 PM