Use a fixed, uniform cell size for hair continuum grids.

This is a bit more awkward for artists to use, but necessary for
a stable solution of the hair continuum calculation. The grid size is
defined by the user, the extent of the grid is then calculated based on
the hair geometry. A hard upper limit prevents bad memory allocation
in case too small values are entered.

Conflicts:
	source/blender/physics/intern/BPH_mass_spring.cpp
This commit is contained in:
Lukas Tönne
2014-11-06 14:05:32 +01:00
parent 8dbb6f0d5d
commit bf96400558
7 changed files with 103 additions and 102 deletions

View File

@@ -153,7 +153,7 @@ void cloth_init(ClothModifierData *clmd )
clmd->sim_parms->goalfrict = 0.0f;
clmd->sim_parms->velocity_smooth = 0.0f;
clmd->sim_parms->voxel_res = 32;
clmd->sim_parms->voxel_cell_size = 0.1f;
if (!clmd->sim_parms->effector_weights)
clmd->sim_parms->effector_weights = BKE_add_effector_weights(NULL);