|
| CHAOS_API | FSphereApproximationParticlePairMidPhase () |
| |
| virtual CHAOS_API void | ResetImpl () override final |
| |
| virtual CHAOS_API void | BuildDetectorsImpl () override final |
| | Build the list of potentially colliding shape pairs. This is all the shape pairs in the partilces' shapes arrays that pass the collision filter.
|
| |
Public Member Functions inherited from Chaos::FParticlePairMidPhase |
| | UE_NONCOPYABLE (FParticlePairMidPhase) |
| |
| CHAOS_API | FParticlePairMidPhase (const EParticlePairMidPhaseType InMidPhaseType) |
| |
| virtual CHAOS_API | ~FParticlePairMidPhase () |
| |
| EParticlePairMidPhaseType | GetMidPhaseType () const |
| |
| CHAOS_API void | Init (FGeometryParticleHandle *InParticle0, FGeometryParticleHandle *InParticle1, const Private::FCollisionParticlePairKey &InKey, const FCollisionContext &Context) |
| | Set up the midphase based on the ShapesArrays of the two particles Only intended to be called once right after constructor. We don't do this work in the constructor so that we can reduce the time that the lock is held when allocating new MidPhases.
|
| |
| FGeometryParticleHandle * | GetParticle0 () const |
| |
| FGeometryParticleHandle * | GetParticle1 () const |
| |
| const Private::FCollisionParticlePairKey & | GetKey () const |
| |
| bool | IsValid () const |
| |
| void | CachePrefetch () |
| |
| bool | IsUsedSince (const int32 Epoch) const |
| | Have we run collision detection since this Epoch (inclusive)
|
| |
| bool | IsSleeping () const |
| | Whether the particle pair is sleeping and therefore contacts should not be culled (they will be reused on wake)
|
| |
| CHAOS_API void | SetIsSleeping (const bool bInIsSleeping, const int32 CurrentEpoch) |
| | Update the sleeping state If this switches the state to Awake, it will reactivate any collisions between the particle pair that were active when they went to sleep.
|
| |
| CHAOS_API bool | IsInConstraintGraph () const |
| |
| CHAOS_API void | DetachParticle (FGeometryParticleHandle *Particle) |
| | Destroy all collisions and prevent this midphasae from being used any more. Called when one of its particles is destoyed. It will be culled at the next Prune in the CollisionConstraintAllocator. We don't delete it immediately so that we don't have to remove it from either Particle's ParticleCollisions array (which is O(N) and unnecessary when the particles are being destroyed)
|
| |
| CHAOS_API void | Reset () |
| | Delete all cached data and collisions. Should be called when a particle changes its shapes.
|
| |
| CHAOS_API void | ResetModifications () |
| |
| CHAOS_API void | GenerateCollisions (const FReal CullDistance, const FReal Dt, const FCollisionContext &Context) |
| | Create collision constraints for all colliding shape pairs.
|
| |
| CHAOS_API void | InjectCollision (const FPBDCollisionConstraint &Constraint, const FCollisionContext &Context) |
| | Copy a collision and activate it This is used by the Resim system to restore saved colisions. If there is already a matching constraint it will be overwritten, otherwise a new constraint will be added.
|
| |
| template<typename TLambda > |
| ECollisionVisitorResult | VisitCollisions (const TLambda &Visitor, const ECollisionVisitorFlags VisitFlags=ECollisionVisitorFlags::VisitDefault) |
| | Call a lambda on each active collision constraint This includes sleeping constraints, but skips constraints that are were not used on the last awake tick but are still kept around as an optimization.
|
| |
| template<typename TLambda > |
| ECollisionVisitorResult | VisitConstCollisions (const TLambda &Visitor, const ECollisionVisitorFlags VisitFlags=ECollisionVisitorFlags::VisitDefault) const |
| | Call a lambda on each active collision constraint.
|
| |
| int32 | GetParticleCollisionsIndex (FGeometryParticleHandle *InParticle) const |
| | Cookie for use by FParticleCollisions.
|
| |
| void | SetParticleCollisionsIndex (FGeometryParticleHandle *InParticle, const int32 InIndex) |
| | Cookie for use by FParticleCollisions.
|
| |
| void | SetIsActive (bool bIsActive) |
| | By default midphases are active. If IsActive is set to false, this midphase will not generate a narrow phase.
|
| |
| void | SetCCDIsActive (bool bCCDIsActive) |
| | Override the CCD condition for this mid-phase. Used by the MidPhase modifier and gets reset every frame.
|
| |
| void | SetConvexOptimizationIsActive (bool bSetConvexOptimizationIsActive) |
| |
| virtual void | SetConvexOptimizationIsActive (bool bSetConvexOptimizationIsActive, TFunctionRef< void(FPBDCollisionConstraint *)> OnDestroyingCollision) |
| | Override whether convex optimization if used this mid-phase. Used by the MidPhase modifier and gets reset every frame. NOTE: when this setting is changed, collisions will be destroyed so any external systems referencing them will need to drop their references.
|
| |
| bool | IsCCD () const |
| |
| bool | IsCCDActive () const |
| |
A midphase for a particle pair that replaces both particles with a sphere approximation