Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Animating rod rest position
#8
(05-05-2021, 06:28 AM)Hakazaba Wrote: What should the Darboux vector of the first particle of the rod be, since it doesn't have a parent particle?

There's not one Darboux vector per particle, but one per constraint. You can think of constraints as the "edges" in between particles. If you have N particles in the rod, there will be N-1 constraints.

Terrible ASCII diagram to the rescue:

Code:
(X)-------(X)-------(X)-------(X)

(X) = particle
------- = constraint

That would be a straight rod. As you can see, there's 4 particles but only 3 constraints.

Keep in mind that Darboux vectors do not determine an absolute orientation, but a change in orientation. So the first darboux vector in the rod will tell you how rod orientation changes from the first particle to the second particle. If it's Quaternion.identity, it will mean that the second particle has the same orientation as the first, however oriented it is.

Quote:I would like to double check that im on the right track. I should use.
actor.solverBatchOffsets[(int)Oni.ConstraintType.BendTwist];
actor.solver.GetConstraintsByType(Oni.ConstraintType.BendTwist)

Correct.

Quote:And if i do, will these values need updating every frame? Or will they be consistant after start?

They will remain set to whatever you set them to. If you want to animate them over time though, you will have to update them every frame to set new values.
Reply


Messages In This Thread
Animating rod rest position - by Hakazaba - 02-05-2021, 02:47 PM
RE: Animating rod rest position - by josemendez - 03-05-2021, 11:05 AM
RE: Animating rod rest position - by Hakazaba - 04-05-2021, 06:12 AM
RE: Animating rod rest position - by josemendez - 04-05-2021, 08:12 AM
RE: Animating rod rest position - by Hakazaba - 04-05-2021, 12:55 PM
RE: Animating rod rest position - by Hakazaba - 05-05-2021, 12:53 AM
RE: Animating rod rest position - by josemendez - 05-05-2021, 09:08 AM
RE: Animating rod rest position - by Hakazaba - 05-05-2021, 06:28 AM
RE: Animating rod rest position - by josemendez - 05-05-2021, 08:10 AM
RE: Animating rod rest position - by Hakazaba - 05-05-2021, 11:54 AM
RE: Animating rod rest position - by josemendez - 05-05-2021, 02:06 PM
RE: Animating rod rest position - by Hakazaba - 05-05-2021, 04:01 PM
RE: Animating rod rest position - by josemendez - 05-05-2021, 05:18 PM
RE: Animating rod rest position - by Hakazaba - 06-05-2021, 04:53 AM
RE: Animating rod rest position - by josemendez - 06-05-2021, 07:38 AM
RE: Animating rod rest position - by Hakazaba - 06-05-2021, 09:12 AM
RE: Animating rod rest position - by josemendez - 06-05-2021, 09:46 AM
RE: Animating rod rest position - by Hakazaba - 06-05-2021, 02:55 PM
RE: Animating rod rest position - by Hakazaba - 08-05-2021, 01:04 AM
RE: Animating rod rest position - by josemendez - 10-05-2021, 09:11 AM
RE: Animating rod rest position - by Hakazaba - 23-05-2021, 04:27 AM
RE: Animating rod rest position - by josemendez - 24-05-2021, 07:37 AM
RE: Animating rod rest position - by Hakazaba - 31-05-2021, 06:53 AM
RE: Animating rod rest position - by josemendez - 31-05-2021, 07:45 AM
RE: Animating rod rest position - by Hakazaba - 01-06-2021, 03:30 AM
RE: Animating rod rest position - by josemendez - 01-06-2021, 07:50 AM
RE: Animating rod rest position - by Hakazaba - 02-06-2021, 05:55 AM
RE: Animating rod rest position - by josemendez - 02-06-2021, 08:00 AM
RE: Animating rod rest position - by Hakazaba - 10-06-2021, 11:38 AM
RE: Animating rod rest position - by josemendez - 10-06-2021, 11:46 AM
RE: Animating rod rest position - by Hakazaba - 11-06-2021, 04:18 PM
RE: Animating rod rest position - by josemendez - 11-06-2021, 04:35 PM
RE: Animating rod rest position - by Hakazaba - 11-06-2021, 06:54 PM
RE: Animating rod rest position - by josemendez - 14-06-2021, 02:15 PM
RE: Animating rod rest position - by Hakazaba - 16-06-2021, 03:33 PM
RE: Animating rod rest position - by josemendez - 16-06-2021, 04:54 PM
RE: Animating rod rest position - by Hakazaba - 16-06-2021, 11:43 PM
RE: Animating rod rest position - by josemendez - 17-06-2021, 08:14 AM
RE: Animating rod rest position - by Hakazaba - 17-06-2021, 02:08 PM
RE: Animating rod rest position - by Hakazaba - 19-06-2021, 03:30 AM
RE: Animating rod rest position - by josemendez - 20-06-2021, 06:24 PM
RE: Animating rod rest position - by Hakazaba - 21-06-2021, 12:00 AM