1
$\begingroup$

I noticed when I enabled soft body self collision, only last half vertices were working properly and first half vertices were working in weird way.

You can set up the following scene easily

  1. Add Sphere Object
  2. Copy Sphere and add 3 more Spheres in Edit Mode
  3. Add Soft Body and Disable Goal and Enable Self Collision

As you can see the behavior of balls are different on left and right, While setting is completely the same and I'm not using any Vertex Group.

Am I doing something wrong or is this a bug?

I'm using Blender 2.79b

enter image description here

$\endgroup$
1
$\begingroup$

The problem is actually due to the geometry of the UV Spheres and how this is interacting with the self-collision as it results in intersecting collision spheres at the start of the simulation resulting in inconsistencies from the start. To understand this you first need to understand a little about how the self-collision works.

Soft Body self-collision acts on the vertices of the mesh - with each vertex being modelled as a sphere that repels any other vertex an each sphere sized independently based on the surrounding mesh. Within the Self Collision properties panel you can configure how Blender calculates the self collision spheres with options of Manual (set a single size for all vertices), Average (set each ball based on the average of the lengths of all of the connected edges), Minimal (based on the shortest connected edge), Maximal (based on the longest connected edge), AvMinMax (based on the average of the shortest and the longest connected edge). The default is to use the Average.

Now consider the geometry of a UV Sphere - particularly at the poles.

At the pole you have a single vertex surrounded by a large number of edges - this should not cause a problem as the collision ball will be based on those edges.

uv sphere pole

Considering the next row of vertices you should see the problem :

second row

Each vertex in this row has two close neighbours and two much more distant neighbours - actually about 5 times as distance as the closest. Using the 'Average' method of ball sizing results in collision balls that are larger than the distance to the next nearest neighbour (ie, if the shorter distance were 1BU then average would equal (1+1+5+5)/4 = 12/4 = 3BU. The default 'ball size' is 0.49, resulting in a ball size of 3*0.49 = 1.47BU - so the vertices are considered as being instantly 'in collision' - and they repel each other.

The solution (to prevent them collapsing) is to change the self-collision ball size to prevent this initial intersection. This can be achieved by changing from 'Average' to 'Minimal' - so that rather than 1.47BU in the above example, the initial size would be 0.49BU so the collision balls would always be separated.

Of course, this doesn't explain why when the spheres are duplicated as in the original example only some of them distort in this way. I suspect that this is actually a bug - although, arguably, it is having to deal with a mesh which is not really suited to Soft Body simulation (as it has vertices with neighbours that are at radically different distances).

The other solution is to use better soft-body-friendly geometry such as Icosphere.

$\endgroup$
  • $\begingroup$ Thank you very much for the detailed reply. Now I understood how self collision works and problem of too short edges and it has to be removed. But still It is not explaining the original problem, I tried with 4 ICO spheres instead of UV spheres, And it resulted in also different behavior between first half and last half vertices. I will consider reporting this as a bug on blender dev forum or something later(I don't know where it is though). $\endgroup$ – Miumiu Aug 4 '18 at 6:51
  • $\begingroup$ I’m actually looking through the softbody source code for other collision issues so I’ll try and spot any self collision issues also. You should definitely raise it though - that way someone far more experienced than me can take an official look. If you do raise it then post a link to the bug report here. $\endgroup$ – Rich Sedman Aug 4 '18 at 10:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.