Blender Git Commit Log

Git Commits -> Revision 84cc91a

Revision 84cc91a by Alexander Gavrilov
November 27, 2021, 18:43 (GMT)
Force Fields: implement new true power and custom falloff options.

The 'power' falloff option in Blender force fields does not actually
generate a true power falloff function, as pointed out in D2389.
However, that patch adds a special 'gravity' falloff option to Force
fields, without addressing the shortcoming in the common options.

The reason for not using the true curve in the options, as far as
one can tell, is that the power curve goes up to infinity as the
distance is reduced to 0, while the falloff options are designed
so that the maximum value of the curve is 1.

However, in reality forces with a power falloff don't actually go
to infinity, because real objects have a nonzero size, and the force
reaches its maximum at the surface of the object. This can be used
to integrate an option to use a true power falloff with the design
of falloff settings, if it requires a nonzero 'minimum' distance
to be set, and uses a curve that reaches 1 at that distance.

Since this is adding a new feature to the minimum distance value,
it is also a good opportunity to add a feature to the maximum
distance. Specifically, the new options can be used to apply
arbitrary brush-style falloff curves between min and max,
including a fully custom curve option. When used together with
power falloff, the two curves are multiplied together.

While the true power option allows creating more physically
correct forces, the custom curves aid artistic effects.

Differential Revision: https://developer.blender.org/D8075

Commit Details:

Full Hash: 84cc91ac1d93ca7f51b52a19b4fe62750817a75b
Parent Commit: 468bc54
Lines Changed: +351, -44

9 Modified Paths:

/release/scripts/startup/bl_ui/properties_physics_common.py (+11, -0) (Diff)
/release/scripts/startup/bl_ui/properties_physics_field.py (+53, -20) (Diff)
/source/blender/blenkernel/BKE_effect.h (+7, -0) (Diff)
/source/blender/blenkernel/BKE_particle.h (+2, -0) (Diff)
/source/blender/blenkernel/intern/effect.c (+143, -14) (Diff)
/source/blender/blenkernel/intern/object.cc (+3, -5) (Diff)
/source/blender/blenkernel/intern/particle.c (+27, -3) (Diff)
/source/blender/makesdna/DNA_object_force_types.h (+22, -2) (Diff)
/source/blender/makesrna/intern/rna_object_force.c (+83, -0) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021