Cleanup: rename getepsilon -> get_epsilon
This commit is contained in:
@@ -224,7 +224,7 @@ static int cloth_collision_response_static ( ClothModifierData *clmd, CollisionM
|
||||
float w1, w2, w3, u1, u2, u3;
|
||||
float v1[3], v2[3], relativeVelocity[3];
|
||||
float magrelVel;
|
||||
float epsilon2 = BLI_bvhtree_getepsilon ( collmd->bvhtree );
|
||||
float epsilon2 = BLI_bvhtree_get_epsilon ( collmd->bvhtree );
|
||||
|
||||
cloth1 = clmd->clothObject;
|
||||
|
||||
@@ -396,7 +396,7 @@ static CollPair* cloth_collision(ModifierData *md1, ModifierData *md2,
|
||||
#endif
|
||||
double distance = 0;
|
||||
float epsilon1 = clmd->coll_parms->epsilon;
|
||||
float epsilon2 = BLI_bvhtree_getepsilon ( collmd->bvhtree );
|
||||
float epsilon2 = BLI_bvhtree_get_epsilon ( collmd->bvhtree );
|
||||
|
||||
tri_a = &clmd->clothObject->tri[overlap->indexA];
|
||||
tri_b = &collmd->tri[overlap->indexB];
|
||||
@@ -909,7 +909,7 @@ static bool cloth_points_collision_response_static(ClothModifierData *clmd, Coll
|
||||
// float w1, w2;
|
||||
float u1, u2, u3;
|
||||
float v1[3], v2_old[3], v2_new[3], v_rel_old[3], v_rel_new[3];
|
||||
float epsilon2 = BLI_bvhtree_getepsilon ( collmd->bvhtree );
|
||||
float epsilon2 = BLI_bvhtree_get_epsilon ( collmd->bvhtree );
|
||||
|
||||
for ( ; collpair != collision_end; collpair++ ) {
|
||||
float margin_distance = (float)(collpair->distance - (double)epsilon2);
|
||||
@@ -1249,7 +1249,7 @@ int cloth_points_objcollision(Object *ob, ClothModifierData *clmd, float step, f
|
||||
|
||||
/* search for overlapping collision pairs */
|
||||
overlap = BLI_bvhtree_overlap(cloth_bvh, collmd->bvhtree, &result, NULL, NULL);
|
||||
epsilon = BLI_bvhtree_getepsilon(collmd->bvhtree);
|
||||
epsilon = BLI_bvhtree_get_epsilon(collmd->bvhtree);
|
||||
|
||||
// go to next object if no overlap is there
|
||||
if (result && overlap) {
|
||||
@@ -1375,7 +1375,7 @@ void cloth_find_point_contacts(Object *ob, ClothModifierData *clmd, float step,
|
||||
|
||||
/* search for overlapping collision pairs */
|
||||
overlap = BLI_bvhtree_overlap(cloth_bvh, collmd->bvhtree, &result, NULL, NULL);
|
||||
epsilon = BLI_bvhtree_getepsilon(collmd->bvhtree);
|
||||
epsilon = BLI_bvhtree_get_epsilon(collmd->bvhtree);
|
||||
|
||||
// go to next object if no overlap is there
|
||||
if (result && overlap) {
|
||||
|
@@ -544,7 +544,7 @@ BVHTreeOverlap *BKE_bmbvh_overlap(const BMBVHTree *bmtree_a, const BMBVHTree *bm
|
||||
|
||||
data.tree_pair[0] = bmtree_a;
|
||||
data.tree_pair[1] = bmtree_b;
|
||||
data.epsilon = max_ff(BLI_bvhtree_getepsilon(bmtree_a->tree), BLI_bvhtree_getepsilon(bmtree_b->tree));
|
||||
data.epsilon = max_ff(BLI_bvhtree_get_epsilon(bmtree_a->tree), BLI_bvhtree_get_epsilon(bmtree_b->tree));
|
||||
|
||||
return BLI_bvhtree_overlap(bmtree_a->tree, bmtree_b->tree, r_overlap_tot, bmbvh_overlap_cb, &data);
|
||||
}
|
@@ -134,7 +134,7 @@ BVHTreeOverlap *BLI_bvhtree_overlap(
|
||||
|
||||
int BLI_bvhtree_get_size(const BVHTree *tree);
|
||||
|
||||
float BLI_bvhtree_getepsilon(const BVHTree *tree);
|
||||
float BLI_bvhtree_get_epsilon(const BVHTree *tree);
|
||||
|
||||
/* find nearest node to the given coordinates
|
||||
* (if nearest is given it will only search nodes where square distance is smaller than nearest->dist) */
|
||||
|
@@ -1123,7 +1123,7 @@ int BLI_bvhtree_get_size(const BVHTree *tree)
|
||||
return tree->totleaf;
|
||||
}
|
||||
|
||||
float BLI_bvhtree_getepsilon(const BVHTree *tree)
|
||||
float BLI_bvhtree_get_epsilon(const BVHTree *tree)
|
||||
{
|
||||
return tree->epsilon;
|
||||
}
|
||||
|
@@ -189,7 +189,7 @@ static void deformVerts(ModifierData *md, Object *ob,
|
||||
|
||||
/* check if GUI setting has changed for bvh */
|
||||
if (collmd->bvhtree) {
|
||||
if (ob->pd->pdef_sboft != BLI_bvhtree_getepsilon(collmd->bvhtree)) {
|
||||
if (ob->pd->pdef_sboft != BLI_bvhtree_get_epsilon(collmd->bvhtree)) {
|
||||
BLI_bvhtree_free(collmd->bvhtree);
|
||||
collmd->bvhtree = bvhtree_build_from_mvert(
|
||||
collmd->current_x,
|
||||
|
@@ -138,7 +138,7 @@ static bool collision_response(ClothModifierData *clmd, CollisionModifierData *c
|
||||
bool result = false;
|
||||
|
||||
float v1[3], v2_old[3], v2_new[3], v_rel_old[3], v_rel_new[3];
|
||||
float epsilon2 = BLI_bvhtree_getepsilon(collmd->bvhtree);
|
||||
float epsilon2 = BLI_bvhtree_get_epsilon(collmd->bvhtree);
|
||||
|
||||
float margin_distance = (float)collpair->distance - epsilon2;
|
||||
float mag_v_rel;
|
||||
|
Reference in New Issue
Block a user