Commit: 5a7f8f8ef89f04799f3ac265858342ae45e690eb
Author: Lukas Tönne
Date:   Fri Nov 14 17:11:33 2014 +0100
Branches: hair_immediate_fixes
https://developer.blender.org/rB5a7f8f8ef89f04799f3ac265858342ae45e690eb

Inverted effect of target density was unstable, the divergence term
needs to be substracted instead.

===================================================================

M       source/blender/physics/intern/hair_volume.cpp

===================================================================

diff --git a/source/blender/physics/intern/hair_volume.cpp 
b/source/blender/physics/intern/hair_volume.cpp
index 4f2f6a3..91198cf 100644
--- a/source/blender/physics/intern/hair_volume.cpp
+++ b/source/blender/physics/intern/hair_volume.cpp
@@ -682,7 +682,7 @@ bool BPH_hair_volume_solve_divergence(HairGrid *grid, float 
dt, float target_den
                                 * and resulting pressure gradient should be 
multiplied by the (inverse) density;
                                 * however, this is already included in the 
weighting of hair velocities on the grid!
                                 */
-                               B[u] = divergence + target;
+                               B[u] = divergence - target;
                                
 #if 0
                                {

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to