|
Blender V5.3
|
#include "draw_shader_shared.hh"#include "draw_shape.bsl.hh"#include "gpu_shader_math_base.bsl.hh"#include "gpu_shader_math_safe.bsl.hh"#include "gpu_shader_math_vector.bsl.hh"Go to the source code of this file.
Classes | |
| struct | IsectPyramid |
| struct | IsectBox |
| struct | IsectFrustum |
| struct | draw::ViewCulling |
Namespaces | |
| namespace | draw |
Functions | |
Plane extraction functions. | |
Intersection library used for culling. Results are meant to be conservative. | |
| float4 | isect_plane_setup (float3 p, float3 v1, float3 v2) |
| IsectPyramid | isect_pyramid_setup (Pyramid shape) |
| IsectBox | isect_box_setup (Box shape) |
| IsectBox | isect_box_setup (float3 origin, float3 side_x, float3 side_y, float3 side_z) |
| IsectFrustum | isect_frustum_setup (Frustum shape) |
Shape vs. Shape Intersection functions. | |
| bool | intersect (IsectPyramid i_pyramid, Box box) |
| bool | intersect (IsectPyramid i_pyramid, IsectBox i_box) |
| bool | intersect (IsectFrustum i_frustum, Pyramid pyramid) |
| bool | intersect (IsectFrustum i_frustum, Box box) |
| bool | intersect (IsectFrustum i_frustum, Sphere sphere) |
| bool | intersect (Cone cone, Sphere sphere) |
| bool | intersect (Circle circle_a, Circle circle_b) |
Definition at line 549 of file draw_intersect.bsl.hh.
References Circle::center, distance_squared(), intersect(), Circle::radius, and square().
Following "Improve Tile-based Light Culling with Spherical-sliced Cone" by Eric Zhang https://lxjk.github.io/2018/03/25/Improve-Tile-based-Light-Culling-with-Spherical-sliced-Cone.html
Definition at line 523 of file draw_intersect.bsl.hh.
References Cone::angle_cos, Sphere::center, Cone::direction, dot(), intersect(), length(), Sphere::radius, safe_rcp(), saturate, and sqrt.
| bool intersect | ( | IsectFrustum | i_frustum, |
| Box | box ) |
Definition at line 464 of file draw_intersect.bsl.hh.
References Box::corners, IsectFrustum::corners, dot(), intersect(), isect_box_setup(), IsectBox::planes, and IsectFrustum::planes.
| bool intersect | ( | IsectFrustum | i_frustum, |
| Pyramid | pyramid ) |
Definition at line 419 of file draw_intersect.bsl.hh.
References IsectFrustum::corners, Pyramid::corners, dot(), intersect(), isect_pyramid_setup(), IsectFrustum::planes, and IsectPyramid::planes.
| bool intersect | ( | IsectFrustum | i_frustum, |
| Sphere | sphere ) |
Definition at line 510 of file draw_intersect.bsl.hh.
References Sphere::center, dot(), intersect(), IsectFrustum::planes, and Sphere::radius.
| bool intersect | ( | IsectPyramid | i_pyramid, |
| Box | box ) |
Definition at line 330 of file draw_intersect.bsl.hh.
References Box::corners, IsectPyramid::corners, dot(), intersect(), isect_box_setup(), IsectBox::planes, and IsectPyramid::planes.
Referenced by blender::BLI_bvhtree_intersect_plane(), blender::bvhtree_intersect_plane_dfs_recursive(), blender::distribute_from_volume_exec(), intersect(), intersect(), intersect(), intersect(), intersect(), intersect(), intersect(), intersect(), intersect(), and blender::particle_intersect_mesh().
| bool intersect | ( | IsectPyramid | i_pyramid, |
| IsectBox | i_box ) |
Definition at line 375 of file draw_intersect.bsl.hh.
References IsectBox::corners, IsectPyramid::corners, dot(), intersect(), IsectBox::planes, and IsectPyramid::planes.
Definition at line 64 of file draw_intersect.bsl.hh.
References A1, Box::corners, dot(), isect_box_setup(), and isect_plane_setup().
Referenced by eevee::shadow::comp_main(), workbench::shadow::visibility::culling_main(), intersect(), intersect(), draw::ViewCulling::intersect_view(), isect_box_setup(), isect_box_setup(), eevee::lightprobe::volume::scene_bounds(), and draw::visibility().
Definition at line 85 of file draw_intersect.bsl.hh.
References dot(), isect_box_setup(), and isect_plane_setup().
| IsectFrustum isect_frustum_setup | ( | Frustum | shape | ) |
Definition at line 113 of file draw_intersect.bsl.hh.
References A1, Frustum::corners, isect_frustum_setup(), and isect_plane_setup().
Referenced by eevee::light::culling::CullingTile::from_corners(), and isect_frustum_setup().
v1 and v2 are vectors on the plane. p is a point on the plane.
Definition at line 27 of file draw_intersect.bsl.hh.
References cross, dot(), isect_plane_setup(), and normalize.
Referenced by isect_box_setup(), isect_box_setup(), isect_frustum_setup(), isect_plane_setup(), and isect_pyramid_setup().
| IsectPyramid isect_pyramid_setup | ( | Pyramid | shape | ) |
Definition at line 38 of file draw_intersect.bsl.hh.
References A1, A2, Pyramid::corners, isect_plane_setup(), and isect_pyramid_setup().
Referenced by intersect(), draw::ViewCulling::intersect_view(), and isect_pyramid_setup().