Skip to content

Commit

Permalink
Clarify Aabb, can be used not as a component, what is it more general…
Browse files Browse the repository at this point in the history
…ly, and how it is not used only for frustum culling
  • Loading branch information
Selene-Amanita committed Jul 17, 2023
1 parent 19c3c8c commit 936a912
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions crates/bevy_render/src/primitives/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@ use bevy_math::{Mat4, Vec3, Vec3A, Vec4, Vec4Swizzles};
use bevy_reflect::Reflect;
use bevy_utils::HashMap;

/// An axis-aligned bounding box.
/// An axis-aligned bounding box, defined by:
/// - a center,
/// - the distances from the center to each faces along the axis,
/// the faces are orthogonal to the axis.
///
/// It represents a box covering the local space occupied by the entity, with faces
/// orthogonal to the local axis.
/// It is typically used as a component on an entity to represent the local space
/// occupied by this entity, with faces orthogonal to its local axis.
///
/// It is typically used as a component on an entity during "frustum culling",
/// a process to determine if the entity should be rendered by a [`Camera`]
/// entity if it intersects with its [`Frustum`].
/// This component is notably used during "frustum culling", a process to determine
/// if the entity should be rendered by a [`Camera`] entity if its bounding box
/// with its [`Frustum`].
///
/// It will be added automatically by the systems in [`CalculateBounds`] to entities that:
/// - could be subject to frustum culling, for example with a [`Handle<Mesh>`]
Expand Down

0 comments on commit 936a912

Please sign in to comment.