I need to consecutively animate a model under certain applied forces. For this purpose, I did some changes in the method “onBeginAnimationStep” so that after animating the model with a certain applied force with specified time steps, the deformed mesh is exported. Then the scene resets (by reseting the state vectors of the MechanicalObject), and then again another force is applied on the mesh until all the forces are applied and finally the animation stops.
My problem here is This:
I need to export the meshes in both formats of .GMSH (for the FEM deformation) and .OBJ (for visual model). The Problem here is that the OBJExporter just exports the file after the animation stops, which means just the last simulation is considered. Does anybody knows how I can fix this problem?
I don’t have this problem for meshExporter, as by selecting the option ‘exportEveryNumberOfSteps’, it exports the meshes from all the simulations. However, this option doesn’t work for for OBJExporter.
The topic ‘How to export .OBJ files at specified time steps, before ending the animation?’ is closed to new replies.
Get involved in this forum: