From d7c4e9649320fdca19d1fa3474a393749d2d7fee Mon Sep 17 00:00:00 2001 From: Germano Cavalcante Date: Fri, 24 Jul 2020 12:07:58 -0300 Subject: Cleanup: Rename 'isect_ray_seg_v3' to 'isect_ray_line_v3' The name was misleading as it returns true whenever it intersects the line represented by the points. --- source/blender/blenlib/intern/math_geom.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'source/blender/blenlib/intern/math_geom.c') diff --git a/source/blender/blenlib/intern/math_geom.c b/source/blender/blenlib/intern/math_geom.c index 79f1aa1e640..ecdf108d00e 100644 --- a/source/blender/blenlib/intern/math_geom.c +++ b/source/blender/blenlib/intern/math_geom.c @@ -630,7 +630,7 @@ float dist_squared_ray_to_seg_v3(const float ray_origin[3], float *r_depth) { float lambda, depth; - if (isect_ray_seg_v3(ray_origin, ray_direction, v0, v1, &lambda)) { + if (isect_ray_line_v3(ray_origin, ray_direction, v0, v1, &lambda)) { if (lambda <= 0.0f) { copy_v3_v3(r_point, v0); } @@ -2129,11 +2129,11 @@ bool isect_ray_seg_v2(const float ray_origin[2], return false; } -bool isect_ray_seg_v3(const float ray_origin[3], - const float ray_direction[3], - const float v0[3], - const float v1[3], - float *r_lambda) +bool isect_ray_line_v3(const float ray_origin[3], + const float ray_direction[3], + const float v0[3], + const float v1[3], + float *r_lambda) { float a[3], t[3], n[3]; sub_v3_v3v3(a, v1, v0); -- cgit v1.2.3