Skip to content

raisim::GripperState ​

struct · #include <raisim/object/ArticulatedSystem/Gripper.hpp>

What a gripper did in the last step (ArticulatedSystem::getGripperState()).

Public attributes ​

engaged ​

cpp
bool engaged

True if the gripper pulled an object, or the link toward a static object, in the last step.

object ​

cpp
const Object *object

The object it held, or nullptr. When the samples of a pad grid pull several bodies, the body that took the largest total pull. Removing an object from the world drops the samples that held it; with none left, this becomes nullptr.

localIdx ​

cpp
size_t localIdx

Local index of the body of the object it held.

force ​

cpp
double force

The pull [N]; the sum over the samples of a pad grid.

gap ​

cpp
double gap

The distance between the pad and the object's surface [m]; zero when they touch. For a pad grid, the smallest gap of the samples that pulled.

position ​

cpp
Vec<3> position

Where the pull acted on the object, in the world frame [m]. For a pad grid, the mean of the points where its samples pulled, weighted by their pulls.

engagedSamples ​

cpp
size_t engagedSamples

The number of samples that pulled: 0 or 1 for a point, up to padSamples[0] * padSamples[1] for a pad grid.

RaiSim — physics for robotics and AI.