Gazebo Gazebo

API Reference

3.15.2
gz/sim/physics/Events.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2021 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 #ifndef GZ_GAZEBO_PHYSICS_EVENTS_HH_
18 #define GZ_GAZEBO_PHYSICS_EVENTS_HH_
19 
20 #include <optional>
21 
22 #include <gz/common/Event.hh>
23 
24 #include <gz/physics/ContactProperties.hh>
25 
26 #include "gz/sim/config.hh"
27 #include "gz/sim/Entity.hh"
28 
29 #include <Eigen/Geometry>
30 
31 namespace ignition
32 {
33  namespace gazebo
34  {
35  // Inline bracket to help doxygen filtering.
36  inline namespace IGNITION_GAZEBO_VERSION_NAMESPACE {
37 
38  namespace events
39  {
40  using Policy = physics::FeaturePolicy3d;
41 
47  using CollectContactSurfaceProperties = gz::common::EventT<
48  void(
49  const Entity& /* collision1 */,
50  const Entity& /* collision2 */,
51  const math::Vector3d & /* point */,
52  const std::optional<math::Vector3d> /* force */,
53  const std::optional<math::Vector3d> /* normal */,
54  const std::optional<double> /* depth */,
55  const size_t /* numContactsOnCollision */,
56  physics::SetContactPropertiesCallbackFeature::
57  ContactSurfaceParams<Policy>& /* params */
58  ),
59  struct CollectContactSurfacePropertiesTag>;
60  }
61  } // namespace events
62  } // namespace gazebo
63 } // namespace ignition
64 
65 #endif // GZ_GAZEBO_PHYSICS_EVENTS_HH_
uint64_t Entity
An Entity identifies a single object in simulation such as a model, link, or light....
Definition: gz/sim/Entity.hh:59
This library is part of the Ignition Robotics project.
physics::FeaturePolicy3d Policy
Definition: gz/sim/physics/Events.hh:40
gz::common::EventT< void(const Entity &, const Entity &, const math::Vector3d &, const std::optional< math::Vector3d >, const std::optional< math::Vector3d >, const std::optional< double >, const size_t, physics::SetContactPropertiesCallbackFeature::ContactSurfaceParams< Policy > &), struct CollectContactSurfacePropertiesTag > CollectContactSurfaceProperties
This event is called when the physics engine needs to collect what customizations it should do to the...
Definition: gz/sim/physics/Events.hh:59