|
AGXDynamics
2.31.1.0
|
Controller that handles compaction in the terrain from generated terrain contacts in TerrainContactGenerator The controller features two methods that calculate stress depth propagation in the terrain soil: BOUSSINESQ - Two part method that calculates the stress field by combining the calculated surface stress and subsoil stress based on the surface contact point loads. More...
#include <CompactionController.h>
Inheritance diagram for agxTerrain::CompactionController:Public Types | |
| enum | CompactionMethod { DENSITY_LOG10, VOID_RATIO_LN } |
| enum | StressCalculationMethod { BOUSSINESQ, UNIFORM_DISK } |
Public Member Functions | |
| CompactionController (Terrain *terrain) | |
| Construct given terrain instance. More... | |
| CompactionController () | |
| bool | applyCompactionFromSurfaceForce (const agx::Vec2i &voxelXY, agx::Real surfaceForce, agx::Real contactTime) |
| Create compaction from an artificially applied surface force. More... | |
| template<typename T > | |
| T * | as () |
| Subclass casting. More... | |
| template<typename T > | |
| const T * | as () const |
| template<typename T > | |
| T * | asSafe () |
| Safe subclass casting, return nullptr if template type does not match. More... | |
| template<typename T > | |
| const T * | asSafe () const |
| CompactionMethod | getCompactionMethod () const |
| Get the compaction method used when calculating compaction. More... | |
| const agx::HashSet< agx::Vec2i > & | getCompressedTerrainIndices () const |
| Get the indices that has been compressed this time step after the post step of the compactionController. More... | |
| int | getReferenceCount () const |
| agx::Real | getStressInVoxel (const agx::Vec3i &voxelIndex) const |
| Get the current active stress in the specified voxelIndex. More... | |
| StressCalculationMethod | getStressMethod () const |
| Get the stress method used when calculating compaction. More... | |
| template<typename T > | |
| bool | is () const |
| Subclass test. More... | |
| void | onPost () |
| The onPost function updates compaction from terrain contacts. More... | |
| void | reference (void *ptr=nullptr) const |
| Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it. More... | |
| void | setCompactionMethod (CompactionMethod compactionMethod) |
| Set the compaction method used when calculating compaction. More... | |
| void | setStressMethod (StressCalculationMethod stressMethod) |
| Set the stress method used when calculating compaction. More... | |
| void | unreference (void *ptr=nullptr) const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. More... | |
| void | unreference_nodelete () const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. More... | |
Static Public Member Functions | |
| template<typename T > | |
| static bool | ValidateCast (const Referenced *object) |
Protected Member Functions | |
| virtual | ~CompactionController () |
| void | allocateObserverVector () const |
| agx::Real | calculateTotalSubSoilStress (const agx::Vec3 &voxelPoint, bool voxelSurfacecIsInContactArea, const TerrainContact::SurfaceForceVector &pointForces) const |
| agx::Bool | compactColumnWithPointForces (const agx::Vec2i &voxelXY, const TerrainContact::SurfaceForceVector &pointForces, agx::Real surfaceStress, bool voxelSurfacecIsInContactArea, agx::Real minDepth, agx::Real maxDepth, agx::Real currentContactTime) |
| agx::Bool | compactColumnWithPointForcesUniformDiskLoad (const agx::Vec2i &voxelXY, agx::Real surfaceStress, agx::Real loadRadius, agx::Real currentContactTime) |
| void | debugRenderStressInNode (const agx::Vec3 &position, agx::Real stress) const |
| void | deleteUsingDeleteHandler () const |
| bool | doCompactionInVoxel (const agx::Vec3i &voxelIndex, agx::Real compactionStress, agx::Real timeFactor) |
| TerrainMassController * | getMassController () const |
| void | handleCompactionFromTerrainContactsBoussinesq (const TerrainContactRefVector &contacts) |
| void | handleCompactionFromTerrainContactsUniformDisk (const TerrainContactRefVector &contacts) |
| void | updateCompactionFromTerrainContacts (const TerrainContactRefVector &contacts) |
| Update compaction from terrain contacts using the chosen stress method. More... | |
Static Protected Member Functions | |
| static DeleteHandler * | getDeleteHandler () |
| static void | setDeleteHandler (DeleteHandler *handler) |
| Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to. More... | |
Protected Attributes | |
| Mutex | m_mutex |
| ObserverContainer | m_observers |
| AtomicValue | m_refCount |
Controller that handles compaction in the terrain from generated terrain contacts in TerrainContactGenerator The controller features two methods that calculate stress depth propagation in the terrain soil: BOUSSINESQ - Two part method that calculates the stress field by combining the calculated surface stress and subsoil stress based on the surface contact point loads.
UNIFORM_DISK - Simple method that approximates the stress propagation by assuming that the surface stress is applied by a circular uniform disk of voxel area in each voxel active in the terrain contact.
Definition at line 48 of file CompactionController.h.
| Enumerator | |
|---|---|
| DENSITY_LOG10 | |
| VOID_RATIO_LN | |
Definition at line 57 of file CompactionController.h.
| Enumerator | |
|---|---|
| BOUSSINESQ | |
| UNIFORM_DISK | |
Definition at line 51 of file CompactionController.h.
| agxTerrain::CompactionController::CompactionController | ( | Terrain * | terrain | ) |
Construct given terrain instance.
| agxTerrain::CompactionController::CompactionController | ( | ) |
|
protectedvirtual |
|
protectedinherited |
| bool agxTerrain::CompactionController::applyCompactionFromSurfaceForce | ( | const agx::Vec2i & | voxelXY, |
| agx::Real | surfaceForce, | ||
| agx::Real | contactTime | ||
| ) |
Create compaction from an artificially applied surface force.
| voxelXY | - The 2D terrain coordinate in voxel space |
| surfaceForce | - The surface force to apply on the surface |
| contactTime | - The contact time that should be used when calculating the relaxation time factor |
|
inherited |
Subclass casting.
Template type must match actual type, dynamic_cast assertion will fail otherwise.
Referenced by agx::InternalData::get(), agxVehicle::Track::getNode(), agx::InternalData::getOrCreate(), and agx::InternalData::hasData().
|
inherited |
|
inherited |
Safe subclass casting, return nullptr if template type does not match.
Referenced by agxUtil::CollectBodiesAndWiresVisitor::visit().
|
inherited |
|
protected |
|
protected |
|
protected |
|
protected |
|
protectedinherited |
|
protected |
| CompactionMethod agxTerrain::CompactionController::getCompactionMethod | ( | ) | const |
Get the compaction method used when calculating compaction.
| const agx::HashSet<agx::Vec2i>& agxTerrain::CompactionController::getCompressedTerrainIndices | ( | ) | const |
Get the indices that has been compressed this time step after the post step of the compactionController.
|
staticprotectedinherited |
|
protected |
|
inherited |
| agx::Real agxTerrain::CompactionController::getStressInVoxel | ( | const agx::Vec3i & | voxelIndex | ) | const |
Get the current active stress in the specified voxelIndex.
| voxelIndex | - The specified voxel index. |
| StressCalculationMethod agxTerrain::CompactionController::getStressMethod | ( | ) | const |
Get the stress method used when calculating compaction.
|
protected |
|
protected |
|
inherited |
Subclass test.
Referenced by agx::Object::getAutoScopedResource(), agxData::EntityStorage::getInstances(), and agx::Object::getResource().
| void agxTerrain::CompactionController::onPost | ( | ) |
The onPost function updates compaction from terrain contacts.
Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.
This method should be used with care, always balanced with the same number of calls to unreference.
| void agxTerrain::CompactionController::setCompactionMethod | ( | CompactionMethod | compactionMethod | ) |
Set the compaction method used when calculating compaction.
|
staticprotectedinherited |
Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to.
| void agxTerrain::CompactionController::setStressMethod | ( | StressCalculationMethod | stressMethod | ) |
Set the stress method used when calculating compaction.
| stressMethod | - The stress method to used when calculating compaction |
Decrement the reference count by one, indicating that a pointer to this object is referencing it.
If the reference count goes to zero, it is assumed that this object is no longer referenced and is automatically deleted.
This method should be used with care, always balanced with the same number of calls to reference.
Referenced by agxData::EntityRef< ContactMaterialPtr >::~EntityRef().
|
inherited |
Decrement the reference count by one, indicating that a pointer to this object is referencing it.
However, do not delete it, even if ref count goes to 0. Warning, unref_nodelete() should only be called if the user knows exactly who will be responsible for, one should prefer unref() over unref_nodelete() as the later can lead to memory leaks.
|
protected |
Update compaction from terrain contacts using the chosen stress method.
Triggered in onPost.
|
staticinherited |
|
mutableprotectedinherited |
Definition at line 240 of file Referenced.h.
|
mutableprotectedinherited |
Definition at line 239 of file Referenced.h.
|
mutableprotectedinherited |
Definition at line 241 of file Referenced.h.