diff options
author | Germano Cavalcante <germano.costa@ig.com.br> | 2017-01-29 19:56:58 +0300 |
---|---|---|
committer | Germano Cavalcante <germano.costa@ig.com.br> | 2017-01-29 19:56:58 +0300 |
commit | cf6ca226fa58d7a03be6cebb73a88eeb57497cf4 (patch) | |
tree | 91d7988cddbcff26a63c5dcaab142701735e4ef5 /source/blender/blenlib/BLI_math_geom.h | |
parent | dead79a16a8e307d6dc2de21380347460c6ddddb (diff) |
New math_geom function `isect_ray_aabb_v3_simple`
The new `isect_ray_aabb_v3_simple` function replaces the `BKE_boundbox_ray_hit_check` and can be used in BVHTree Root (first AABB). So it is much more efficient.
Diffstat (limited to 'source/blender/blenlib/BLI_math_geom.h')
-rw-r--r-- | source/blender/blenlib/BLI_math_geom.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenlib/BLI_math_geom.h b/source/blender/blenlib/BLI_math_geom.h index e3635be671f..4a85e859c16 100644 --- a/source/blender/blenlib/BLI_math_geom.h +++ b/source/blender/blenlib/BLI_math_geom.h @@ -293,6 +293,10 @@ void isect_ray_aabb_v3_precalc( bool isect_ray_aabb_v3( const struct IsectRayAABB_Precalc *data, const float bb_min[3], const float bb_max[3], float *tmin); +bool isect_ray_aabb_v3_simple( + const float orig[3], const float dir[3], + const float bb_min[3], const float bb_max[3], + float *tmin, float *tmax); struct NearestRayToAABB_Precalc { float ray_origin[3]; |