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!
I want to do collision detection between animated meshes (*.md2). but the triangle selector "createOctTreeTriangleSelector" works only with static meshes as given in Example 4 in Irrlicht SDK. How should I proceed with animated meshes for collision detection.
Simply don't use OctTrees. This does not make sense for animated meshes, it's for large terrains or worlds. There are simple triangle selectors and collision response animators which you can use.