Before Mantaflow (2.82+), we were able to bake smoke sims with custom python code like follows:
o = bpy.context.selected_objects[0]
c = {}
c['point_cache'] = o.modifiers['Smoke'].domain_settings.point_cache
bpy.ops.ptcache.bake(c, bake=True)
o in this case is the selected object (Smoke Domain), while c is a custom context supplied to the op. Now with Mantaflow, I've tried the following, which causes Blender to crash:
o = bpy.context.selected_objects[0]
c = {}
c['point_cache'] = o.modifiers['Fluid'].domain_settings.point_cache
bpy.ops.fluid.bake_data(c)
Resulting error isn't much help:
Error : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FF71D40835C
Module : C:\Program Files\Blender Foundation\Blender 2.82\blender.exe
What is the correct way of calling fluid.bake_data() in custom python code?
Thanks for your help!
bpy.ops.fluid.bake_all()– d2kagw Jun 06 '20 at 21:58