Interface IStaticChangeAwakeningFilter
- Namespace
- BepuPhysics
- Assembly
- BepuPhysics.dll
Defines a type that determines which bodies should be awoken in the bounding box of a static when the static's state changes.
public interface IStaticChangeAwakeningFilter
Remarks
We cannot find bodies depending on a static through constraints, since statics do not maintain constraint lists. When a static is added, removed, has SetShape or has ApplyDescription called on it, it looks up bodies in its bounding box that could possibly be affected by change and considers waking them up. This filter can be used to ignore some bodies.
Properties
AllowAwakening
Gets whether to allow awakening for any body. If true, candidates will have the ShouldAwaken function called for them. If false, ShouldAwaken will not be called, and no bodies will be awoken.
bool AllowAwakening { get; }
Property Value
Methods
ShouldAwaken(BodyReference)
Determines whether a body should be forced awake by the state change of a static.
bool ShouldAwaken(BodyReference body)
Parameters
body
BodyReferenceSleeping body under consideration for awakening.
Returns
- bool
True if the body should be forced awake, false otherwise.