You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers. No questions about C++ programming or topics which are answered in the tutorials!
Where d is the displacement (in millimeters), P is the force (in Newtons), L is the length to the point of bending (ie, in your image, you would calculate this at four points), E is the modulus of elasticity of the material (steel = 210,000 MPa), and I is the moment of inertia.
To calculate the moment of inertia, you need the cross-section of the stick. Lets say it's round, then we use:
I=pi*r^4/4
Where r is the radius of the cross-section.
Cheers,
Pinky
Intellectuals solve problems - geniuses prevent them. -- Einstein
#irrlicht on irc.freenode.net
That is assuming that the force applied is always perpendicular to the tip of the stick. If the vector of the force is constant ( like for example gravity on a stick hanging out sideways) then as the stick deforms, the angle of the force applied to the tip of the stick will change. You may or may not want to correct for this depending on how accurate you want your simulation to be.
With a force that is aways perpendicular to the tip and given enough force applied, the stick will form a spiral. This is not the case if the vector of the force remains constant.
My method is only valid for small displacements anyway. It is just a suggestion of a method - you need to try it, and see if it is good enough for what you need.
Intellectuals solve problems - geniuses prevent them. -- Einstein
#irrlicht on irc.freenode.net
if you want to use bones, you can set bone positions using acki's x custom bones patch.
but for such a simple mesh as a stick it would be just as easy to move the vertices of your mesh manually.
use smgr->getMeshManipulator()->createMeshCopy(IAnimatedMesh->getMesh(0)) to get an SMesh from your model file, then you can access the SMeshBuffer and deform it by setting the positions of the vertices.
start your journey into the docs at the mesh manipulator and finish somewhere around SMeshBuffer. (you'll need to cast SMesh->getMeshBuffer to an SMeshBuffer)