AGX Dynamics 2.38.0.2
Loading...
Searching...
No Matches
TerrainJournalRecorder.h
Go to the documentation of this file.
1/*
2Copyright 2007-2024. Algoryx Simulation AB.
3
4All AGX source code, intellectual property, documentation, sample code,
5tutorials, scene files and technical white papers, are copyrighted, proprietary
6and confidential material of Algoryx Simulation AB. You may not download, read,
7store, distribute, publish, copy or otherwise disseminate, use or expose this
8material unless having a written signed agreement with Algoryx Simulation AB, or having been
9advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10valid commercial license from Algoryx Simulation AB.
11
12Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13from using this software, unless otherwise stated in written agreements with
14Algoryx Simulation AB.
15*/
16
17#pragma once
18
19#include <agxTerrain/Terrain.h>
20#include <agx/Journal.h>
22
23namespace agxTerrain
24{
25
36 {
37 public:
42 static TerrainJournalRecorder* find( const agxTerrain::Terrain* terrain, const agxSDK::Simulation* simulation );
43
47 static size_t addTerrainJournalRecorders( agxSDK::Simulation* simulation );
48
49 public:
55
60 virtual void preCollide( const agx::TimeStamp& time ) override;
61
66 virtual void pre( const agx::TimeStamp& time ) override;
67
72 virtual void post( const agx::TimeStamp& time ) override;
73
75 virtual void addNotification() override;
76
79
81
82 protected:
83
85
87
89
91
93
95
97
99
101
102 private:
104
106 // Variables
108 protected:
116 };
117}
#define AGX_DECLARE_POINTER_TYPES(type)
Definition Referenced.h:254
#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
Abstract representation of a data buffer.
Definition Buffer.h:56
Simulation is a class that bridges the collision space agxCollide::Space and the dynamic simulation s...
Definition Simulation.h:126
Derive from this class to implement a listener for simulation step events.
agxData::Buffer * getHeightBuffer()
static TerrainJournalRecorder * find(const agxTerrain::Terrain *terrain, const agxSDK::Simulation *simulation)
Finds TerrainJournalRecorder given terrain and simulation.
TerrainJournalRecorder(agxTerrain::Terrain *terrain)
Constructor for the TerrainJournalRecorder.
void createJournalBindings(agx::Journal *journal)
agxTerrain::Terrain * getTerrain()
Get the coupled terrain object.
virtual void preCollide(const agx::TimeStamp &time) override
Called before the collision detection step is taken in the simulation.
void journalAttachedCallback(agxSDK::Simulation *simulation, agx::Journal *journal)
static size_t addTerrainJournalRecorders(agxSDK::Simulation *simulation)
Find all active terrains in the simulation and add a TerrainJournalRecorder objects for each one.
virtual void post(const agx::TimeStamp &time) override
Called after a step is taken in the simulation.
agxSDK::Simulation::JournalAttachEvent::CallbackType m_journalAttachedCallback
virtual void pre(const agx::TimeStamp &time) override
Called before a step is taken in the simulation.
virtual void addNotification() override
Called when this object is added to a simulation.
A terrain model based a 3D grid model with overlapping height field that can be deformed by interacti...
Definition Terrain.h:86
T CallbackType
Definition Event.h:37
A UUID, or Universally unique identifier, is intended to uniquely identify information in a distribut...
Definition Uuid.h:42
The agxTerrain namespace contains a 3D model for a dynamic deformable Terrain and related classes.
Definition Geometry.h:59
agx::Real TimeStamp
Definition TimeStamp.h:26