First of all I’m new to three js and 3d graphics. I’m working on certain problem: there are two identical longitudinal meshes (I started with 2 cyllinders to make it simpler to experiment), which can bend in two places to the degree chosen by the user - something like that:
Above scene was made in Blender 2.83, I added two cyllinders and connected each with armature made of three bones. Then I exported it as gltf and loaded to program. However, I need both bended cyllinders (and in final project more complicated meshes) to be parallel at every point. As I calculated, that requires to increase length of bones of the right cyllinder (or left if bending in opposite direction) by a*tan(angle) with ‘a’ being distance between cyllinders and ‘angle’ being the rotation angle. As I read, the only way to increase bone length is to change its scale. But when I try to do that entire cyllinder above first bone distorts and angle of bend also changes:
So my question is whether there is a way to just lengthen the bones and preserve shape and radius of cyllinder? Or maybe is there a better way to solve my problem? Thank you for any help.