16#ifndef AGXCOLLIDE_SWEEPANDPRUNE_H
17#define AGXCOLLIDE_SWEEPANDPRUNE_H
76 virtual void run()
override;
99 void insertNewGeometries();
101 void tagRemovedBounds();
102 void sortAxis(
int axis);
103 void removeGeometries();
126#if HASH_FOR_SWEEP == HASH_NEW
128#elif HASH_FOR_SWEEP == HASH_OLD
139 std::priority_queue<agx::UInt32, std::deque<agx::UInt32>, queuecmp> m_holes;
143 typedef std::pair<GeometryRef, agx::UInt32> RemovedGeometry;
147 saptable m_contactTable;
148 saptable m_impactTable;
149 saptable m_separationTable;
152 void insertNewGeometry( Geometry* geom,
agx::UInt32 axis,
size_t insertIndex,
size_t endpointIndex );
155 GeometryRefSet m_addGeometries;
156 RemovedGeometrySet m_removeGeometries;
160 size_t m_numBoxesAvailable;
161 size_t m_numEndpointsAvailable;
169#if HASH_FOR_SWEEP == HASH_NEW
171#elif HASH_FOR_SWEEP == HASH_OLD
176 ActivePairTable m_activePairs;
#define AGX_DECLARE_POINTER_TYPES(type)
#define AGXPHYSICS_EXPORT
Axis aligned bounding box implementation.
The geometry representation used by the collision detection engine.
This class contains all Geometries and performs Broad Phase and Narrow Phase collision detection to c...
virtual void run() override
Execution callback.
UpdateTask(const agx::String &name, SweepAndPrune *sap)
void add(Geometry *geometry)
virtual bool testOverlap(agxCollide::GeometryPtrVector &testGeometries, agxCollide::GeometryPairVector &result, bool skip)
void removePair(const agxCollide::Geometry *geometry1, const agxCollide::Geometry *geometry2)
Remove broad phase overlap given two geometries.
agx::Physics::BroadPhasePairPtr getPair(const Geometry *geometry1, const Geometry *geometry2) const
agx::SymmetricPair< GeometryRef > SymmetricGeometryRefPair
void remove(Geometry *geometry)
agx::HashVector< SymmetricGeometryPtrPair, SymmetricGeometryRefPair > ExternallyReportedPairsContainer
virtual ~SweepAndPrune(void)
agx::Task * createUpdateTask()
SweepAndPrune(Space *space)
Default constructor.
void commitNewOverlaps(agxData::EntityStorage *pairStorage, ExternallyReportedPairsContainer &newPairs)
agx::SymmetricPair< Geometry * > SymmetricGeometryPtrPair
Data storage for a collection of entity instances of a specified EntityModel.
A component is an object containing other objects, enabling hierarchical structuring.
Inheritance with partial specialization due to bug with ref_ptr containers.
Inheritance with partial specialization due to bug with ref_ptr containers.
Pointer to a entity instance of type Physics.BroadPhasePair.
Inheritance with partial specialization due to bug with ref_ptr containers.
A std::pair, with both elements of the same type, and symmetric so (a, b) == (b, a)
A representation of a generic task.
Vector containing 'raw' data.
#define DOXYGEN_END_INTERNAL_BLOCK()
#define DOXYGEN_START_INTERNAL_BLOCK()
This namespace consists of a set of classes for handling geometric intersection tests including boole...