Bendy Bone that matches a curve?

But then I’ll have a chain of bendy bones, no? I need one bone with 30 segments, not 5 bones with 6 segments. Unless there’s a way to convert a chain to a single bone?

If you follow the video, you only need a curve with 3 vertices. Each one becomes a bone.

I already have a bbone with a head and tail. I’m trying to adjust the big bbone to match a curve. Here’s a gif of me doing it manually. But its imprecise. I’m trying to figure out how to automate this by understanding the relationship between the bezier curve handles and the bbone Ease in and out settinigs.

Making multiple bones along a curve is a different issue.

It looks to me like if a curve segment corresponds to a bendy bone segment (start and end segment included) then the shape should be the same as the curve.

It depends on the control points of the curve. If you scale or move the handles, the curve becomes more extreme. In the case of the bendybones, the start/end are defining the rotation of the handle, but scaling them doesn’t do anything. Instead you adjust the Ease In/Out. So i’m trying to figure out what the relationship is between handle position and Ease In/Out is.

Can’t you reduce the number of bones according to ChainTools and then increase it again in bendy bone. Maybe the curve data will be retained.

It doesn’t retain it :frowning:

I’m sorry about that. Then I guess we’ll have to find another addon.

1 Like
  • The length of each handle (hlength1 and hlength2 respectively) is based on the “ Ease In/Out ” properties, the length of the bone, and a magic-number factor (“0.5f * sqrt(2) * kappa”, where kappa = the handle length – apparently this formula allows “for near-perfect circles”). i.e.,

hlength1 = ease_in * length * 0.390464f hlength2 = ease_out * length * 0.390464f

1 Like

Wonderful, that seems to work in my tests!

So I’ve got a script working where it adjusts the Ease In/Out based on the curve’s handle length:

But now there’s a new issue. I’ve set it up to also follow rotation (via the handle pointing at another bone that follows the curve handle position), but i’m getting some offset.

This offset is caused by the effective length of the bbone changing, but not the actual length value. The bbone is currently 2 units long, and if you apply this pose, it is still 2 units long. So the extra length that comes from Ease In/Out stretching it is not reflected in the length value, and so continuing to use the base length gives the wrong results.

There doesn’t seem to be any part of the data api that tells me the true length of a bbone. So I need to figure out some amount to adjust the base length by based on the Ease In and Out amounts. Any ideas?

EDIT: On further inspection, I’m not sure that the problem is caused by Ease changing the length. It may be some other discrepancy between the bones and curve. You can see here that the bone and curve lines up just right when the handle is at 90 deg to the original path of the bone, but then the length starts being wrong in one direction or the other as its rotated. But moving the ctrl point handle further away stretches the bone and curve, but does not cause additional problems in their alignment.

Did you set it up with drivers? Can you share that scene on gifs?

Its Animation Nodes.

bendy bone match curve_share.blend (894.2 KB)

1 Like

This setup looks promising, I’ll try to reproduce it as it is now but please keep this updated if you find a way to match the curve 100%!

1 Like

I’ve only spent a little more time on it and have not figured out how to deal with the offset when rotating it. Let me know if you’ve got any insight!

1 Like

Any news on this ?

1 Like

Afraid not. I haven’t returned to this as I don’t have any leads on what the issue could be :frowning:

I recongnized that if you rotate both handles with the same angle so the angle in between is the same it works.
Here is a small script and a simple setup to test… will defently test further and find hopfully a solution.bendy_curve_test.blend (789.4 KB)

2 Likes

Hi here is a script to test easein and out as a driver to match the curve.
I made both handles parallel so the vector angle in between is 0 and try to match by hand the curve by adjusting ease in and out. This number is then multiplied by the angle between the vectors to get a relationship.
In the previous formula i tried also by hand to match the right factor if the vectors are paralel.
so factor1 = factor2 and 1 = 90° = pi/ 2.
Anyway here is the testfile…its not perfect but i my view good enough.bendy_curve_test_02.blend (895.5 KB)

1 Like

Just saying, by adding a distance driver you can get some kind of auto-tangent behavior:

There is the classic B-Bone twisting problem, not sure if the same as that old 2011 one… https://developer.blender.org/T26090

1 Like