Modifying a macro to create videos


i have created a macro that has the function of loading the vtu and vtp files from a simulation that has been run, creating a video of the entire time period and then saving it.
I now want to modify the macro so that I can apply it to multiple folders at once. I have used a for-loop to do this. Also, per folder the particle diameter is different, which I would solve through an if-condition. Unfortunately my modified macro does not work. I have not worked much with Paraview so I would appreciate if someone could answer me whether this would work in general and has tips for setting up the macro.

Hi @RoLe

Unfortunately my modified macro does not work.

Please share your macro


Hi @mwestphal,
thanks for the response. I have attached my macro. (13.8 KB)

I’d suggest to rework your macro to avoid doing all the work in the loop.

Do it once, then change only what is needed in the loop.

  • filename (based on folder)
  • particle diameter
  • then update the pipeline