From 78ff8526808a4fbc3d261155b1e6f873247ff8ce Mon Sep 17 00:00:00 2001 From: Alexander Gavrilov Date: Sat, 9 Jan 2021 22:24:48 +0300 Subject: Force Fields: implement early filtering by the Affect flags. Most fields have Affect Location and Rotation options that switch off their effect, but they are only checked as the last step after the force is already computed. It is more efficient to check it when building the list of field objects, just like zero weight. It is also possible to check the strength-related fields for 0. As an aside, this adds Location to Texture fields (they don't handle rotation) and both Location & Rotation checkboxes to Fluid Flow. Boid and Curve Guide remain without options for now as they are completely different from others. Differential Revision: https://developer.blender.org/D10087 --- source/blender/blenkernel/intern/fluid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/blenkernel/intern/fluid.c') diff --git a/source/blender/blenkernel/intern/fluid.c b/source/blender/blenkernel/intern/fluid.c index 59248e5f9f8..7fe009d51ca 100644 --- a/source/blender/blenkernel/intern/fluid.c +++ b/source/blender/blenkernel/intern/fluid.c @@ -3225,7 +3225,7 @@ static void update_effectors( ListBase *effectors; /* make sure smoke flow influence is 0.0f */ fds->effector_weights->weight[PFIELD_FLUIDFLOW] = 0.0f; - effectors = BKE_effectors_create(depsgraph, ob, NULL, fds->effector_weights); + effectors = BKE_effectors_create(depsgraph, ob, NULL, fds->effector_weights, false); if (effectors) { /* Precalculate wind forces. */ -- cgit v1.2.3