37 class TerrainDataSource;
220 inline bool getDeformable()
const;
226 void setEmbedCacheFilesInArchive(
bool embed );
232 bool getEmbedCacheFilesInArhive()
const;
379 const agx::Vec2i& sourceIndex,
bool shouldSynchronizeCompaction);
396 RAYCAST_RESULT_FROM_DATASOURCE
415 using StepEventListener::store;
417 using StepEventListener::restore;
463 void setBlockingCallbacks(
479 void updateActiveTiles();
481 void unloadUnusedTiles(
bool partOfRemoveNotification );
485 void unloadAllTiles();
487 void prepareSimulation(
bool fromRestore);
500 bool shouldSynchronizeCompaction);
502 bool isIndexWithinTileMargin(const
agx::Vec2i& terrainIndex) const;
507 friend class
agx::InternalData;
511 agx::Referenced* getInternalData() const;
516 void setInternalData(
agx::Referenced* data );
518 agx::ref_ptr<
agx::Referenced> m_internalData;
526 bool m_shouldStoreDeltas;
530 bool m_shouldSynchronizeCompaction;
532 struct BodyAttachments {
540 typedef std::pair<TileId, agx::Vec2i> GlobalTerrainIndex;
543 agx::HashTable < agx::RigidBody *, BodyAttachments > m_bodies;
563 void fillHeightDelta(
const GlobalTerrainIndex& gtid,
agx::Real height);
568 inline void TerrainPager::fillHeightDelta(
const GlobalTerrainIndex& gtid,
agx::Real height)
570 m_heightFieldDelta[gtid] = height;
#define AGX_DECLARE_POINTER_TYPES(type)
#define AGXSTREAM_DECLARE_SERIALIZABLE(T)
Use this in a Serializable class to add the required methods Important: Use full namespace in the dec...
#define AGXTERRAIN_EXPORT
#define AGX_DECLARE_VECTOR_TYPES(type)
Derive from this class to implement a listener for simulation step events.
Shovel object used to interact with a terrain via an active zone that converts solid terrain to dynam...
Interface class for accessing data and functions for the internal soil particle simulation used in ag...
The TerrainCache is used internally by the TerrainPager to provide requested terrain tiles.
std::function< void *()> PreBlockFunc
void setEmbedCacheFilesInArchive(bool embed)
Sets if cached files written out to disk should be embeded in AGX Archives when store is called.
agxTerrain::TerrainRef getTemplateTerrain()
Returns the template terrain used for properties of new terrain tiles.
void setBlockingCallbacks(PreBlockFunc preBlock, PostBlockFunc postBlock)
Set callbacks invoked before and after the main thread blocks waiting for the background thread (wait...
bool getEmbedCacheFilesInArhive() const
Returns if cached files should be embedded in AGX Archives used for serialization.
std::function< void(void *)> PostBlockFunc
Abstract interface for requesting height data for a Terrain tile.
TerrainWheel is a rigid tire model that can deform soft terrain, modeled by agxTerrain::Terrain objec...
A terrain model based a 3D grid model with overlapping height field that can be deformed by interacti...
A TileSpecification determines where in the world a 2D TileId is located and contains utility methods...
Templated callback with two arguments.
An event with two arguments.
Inheritance with partial specialization due to bug with ref_ptr containers.
Inheritance with partial specialization due to bug with ref_ptr containers.
The rigid body class, combining a geometric model and a frame of reference.
#define DOXYGEN_END_INTERNAL_BLOCK()
#define DOXYGEN_START_INTERNAL_BLOCK()
The agxTerrain namespace contains a 3D model for a dynamic deformable Terrain and related classes.
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
std::pair< Real, Real > RealPair
Struct with data to describe a terrain tile.