IRockyDeviceModel Struct Reference
Last update: 17.07.2025#include <rocky_model_api.hpp>
Public Member Functions | |
| ROCKY_FUNCTIONS double | get_timestep () const |
| ROCKY_FUNCTIONS double | get_current_time () const |
| ROCKY_FUNCTIONS IRockyCloudPoint | get_particle_cloud_point (int point_cloud_index, const IRockyParticle &particle) |
| ROCKY_FUNCTIONS IRockyPairScalars | get_pair_scalars (int pair_index) |
| ROCKY_FUNCTIONS IRockyGeometryScalars | get_geometry_scalars (int geometry_index) |
Detailed Description
IRockyDeviceModel includes auxiliary functions that are available only during the execution of a simulation. Hooks such as ROCKY_PLUGIN_PRE_FORCE..., ROCKY_PLUGIN_POST_FORCE..., and ROCKY_PLUGIN_PRE_MOVE..., provide an IRockyDeviceModel object as a parameter.
Member Function Documentation
◆ get_current_time()
| ROCKY_FUNCTIONS double IRockyDeviceModel::get_current_time | ( | ) | const |
- Returns
- The value of the current time in the simulation.
◆ get_geometry_scalars()
| ROCKY_FUNCTIONS IRockyGeometryScalars IRockyDeviceModel::get_geometry_scalars | ( | int | geometry_index | ) |
- Returns
- An
IRockyGeometryScalarsobject, that gives access to all geometry scalars defined in a project.
- Parameters
-
geometry_index The index that identifies a specific geometry within a Rocky project.
◆ get_pair_scalars()
| ROCKY_FUNCTIONS IRockyPairScalars IRockyDeviceModel::get_pair_scalars | ( | int | pair_index | ) |
- Returns
- An
IRockyPairScalarsobject, that gives access to all pair scalars defined in a project.
- Parameters
-
pair_index The index that identifies a specific pair of particle groups or a pair formed by a particle group and a geometry.
◆ get_particle_cloud_point()
| ROCKY_FUNCTIONS IRockyCloudPoint IRockyDeviceModel::get_particle_cloud_point | ( | int | point_cloud_index, |
| const IRockyParticle & | particle | ||
| ) |
- This function gets an auxiliary object that gives access
- to cloud point values of the nearest point to a given particle.
- Parameters
-
point_cloud_index The index that uniquely identifies a point cloud dataset. particle A IRockyParticlewhose position is used to determine the nearest cloud point.
- Returns
- An
IRockyParticleCloudPointobject, which can be used to get cloud point values of the nearest point to the particle passed as argument. For more information about point clouds, please refer to the Rocky User Manual.
◆ get_timestep()
| ROCKY_FUNCTIONS double IRockyDeviceModel::get_timestep | ( | ) | const |
- Returns
- The value of the simulation timestep.