Skip to content
Snippets Groups Projects
Commit 730d0ade authored by Johannes Mey's avatar Johannes Mey
Browse files

fix for gazebo11

parent baf0f033
No related branches found
No related tags found
No related merge requests found
......@@ -55,6 +55,7 @@ endif()
# include_directories(include)
include_directories(
include
/usr/include/ffmpeg
${catkin_INCLUDE_DIRS}
${GAZEBO_INCLUDE_DIRS}
)
......
......@@ -64,6 +64,7 @@ endif()
# include_directories(include)
include_directories(
include
/usr/include/ffmpeg
${catkin_INCLUDE_DIRS}
${GAZEBO_INCLUDE_DIRS}
)
......
......@@ -157,7 +157,7 @@ shape_msgs::SolidPrimitive * GazeboObjectInfo::getSolidPrimitive(physics::Collis
else
{
ROS_WARN("shape type %i of collision %s not supported. Using bounding box instead. ", c->GetShapeType(),c->GetName().c_str());
gz_math::Box box = GetBoundingBox(*c);
gz_math::AxisAlignedBox box = GetBoundingBox(*c);
GzVector3 bb = GetBoundingBoxDimensions(box);
if ((GetX(bb) < 1e-05) || (GetY(bb) < 1e-05) || (GetZ(bb) < 1e-05)){
ROS_WARN_ONCE("Skipping coll %s because its bounding box is flat",c->GetName().c_str());
......
......@@ -50,6 +50,7 @@ endif()
## Your package locations should be listed before other locations
include_directories(
include
/usr/include/ffmpeg
${catkin_INCLUDE_DIRS}
${GAZEBO_INCLUDE_DIRS}
)
......
......@@ -116,7 +116,7 @@ std::string GetName(const T& t)
///////////////////////////////////////////////////////////////////////////////
template<typename T>
gz_math::Box GetBoundingBox(const T &t)
gz_math::AxisAlignedBox GetBoundingBox(const T &t)
{
#if GAZEBO_MAJOR_VERSION >= 8
return t.BoundingBox();
......@@ -126,7 +126,7 @@ gz_math::Box GetBoundingBox(const T &t)
}
///////////////////////////////////////////////////////////////////////////////
GzVector3 GetBoundingBoxDimensions(const gz_math::Box &box);
GzVector3 GetBoundingBoxDimensions(const gz_math::AxisAlignedBox &box);
///////////////////////////////////////////////////////////////////////////////
template<typename T>
......
......@@ -314,7 +314,7 @@ gazebo::physics::Model_V gazebo::GetModels(
}
///////////////////////////////////////////////////////////////////////////////
gazebo::GzVector3 gazebo::GetBoundingBoxDimensions(const gz_math::Box &box)
gazebo::GzVector3 gazebo::GetBoundingBoxDimensions(const gz_math::AxisAlignedBox &box)
{
#if GAZEBO_MAJOR_VERSION >= 8
GzVector3 bb(box.XLength(), box.YLength(), box.ZLength());
......
......@@ -55,6 +55,7 @@ endif()
# include_directories(include)
include_directories(
include
/usr/include/ffmpeg
${catkin_INCLUDE_DIRS}
${GAZEBO_INCLUDE_DIRS}
)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment