Blender Git Loki
Git Commits -> Revision 980dd43
Revision 980dd43 by Jacques Lucke (master) July 22, 2020, 12:16 (GMT) |
Particles: give emitter its own state High quality emitters need to maintain state themselves. For example, this it needs to remember when it spawned the last particle. This is especially important when the birth rate is changing over time. Otherwise, there will be very visible artifacts. It is quite likely that other components of the simulation need their own state as well. Therefore, I refactored the `SimulationState` type a bit, to make it more extensible. Instead of using hardcoded type numbers, a string is used to identify the state type. Also, instead of having switch statements in many places, there is a new `SimulationStateType` that encapsulates information about how a specific state is created/freed/copied/... I removed the integration with the point cache for now, because it was not used anyway in it's current state. |
Commit Details:
Full Hash: 980dd43bd4be7d5f2d893148984e5fd96c5747f4
Parent Commit: 47b6c33
Lines Changed: +426, -300
13 Modified Paths:
/source/blender/blenkernel/BKE_pointcache.h (+0, -5) (Diff)
/source/blender/blenkernel/BKE_simulation.h (+14, -1) (Diff)
/source/blender/blenkernel/intern/pointcache.c (+1, -86) (Diff)
/source/blender/blenkernel/intern/simulation.cc (+211, -66) (Diff)
/source/blender/blenloader/intern/readfile.c (+4, -8) (Diff)
/source/blender/blenloader/intern/writefile.c (+25, -23) (Diff)
/source/blender/makesdna/DNA_simulation_types.h (+10, -13) (Diff)
/source/blender/modifiers/intern/MOD_simulation.cc (+2, -14) (Diff)
/source/blender/simulation/intern/simulation_collect_influences.cc (+36, -15) (Diff)
/source/blender/simulation/intern/simulation_collect_influences.hh (+32, -3) (Diff)
/source/blender/simulation/intern/simulation_solver.cc (+8, -7) (Diff)
/source/blender/simulation/intern/simulation_solver.hh (+57, -0) (Diff)
/source/blender/simulation/intern/simulation_update.cc (+26, -59) (Diff)
/source/blender/blenkernel/BKE_simulation.h (+14, -1) (Diff)
/source/blender/blenkernel/intern/pointcache.c (+1, -86) (Diff)
/source/blender/blenkernel/intern/simulation.cc (+211, -66) (Diff)
/source/blender/blenloader/intern/readfile.c (+4, -8) (Diff)
/source/blender/blenloader/intern/writefile.c (+25, -23) (Diff)
/source/blender/makesdna/DNA_simulation_types.h (+10, -13) (Diff)
/source/blender/modifiers/intern/MOD_simulation.cc (+2, -14) (Diff)
/source/blender/simulation/intern/simulation_collect_influences.cc (+36, -15) (Diff)
/source/blender/simulation/intern/simulation_collect_influences.hh (+32, -3) (Diff)
/source/blender/simulation/intern/simulation_solver.cc (+8, -7) (Diff)
/source/blender/simulation/intern/simulation_solver.hh (+57, -0) (Diff)
/source/blender/simulation/intern/simulation_update.cc (+26, -59) (Diff)