Skip to content

Commit

Permalink
Showing 8 changed files with 11 additions and 66 deletions.
4 changes: 1 addition & 3 deletions tpe/lib/src/AABBTree.cc
Original file line number Diff line number Diff line change
@@ -53,9 +53,7 @@ AABBTree::AABBTree()
}

//////////////////////////////////////////////////
AABBTree::~AABBTree()
{
}
AABBTree::~AABBTree() = default;

//////////////////////////////////////////////////
void AABBTree::AddNode(std::size_t _id, const math::AxisAlignedBox &_aabb)
2 changes: 1 addition & 1 deletion tpe/lib/src/Collision.hh
Original file line number Diff line number Diff line change
@@ -47,7 +47,7 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE Collision : public Entity
public: Collision(const Collision &_other);

/// \brief Destructor
public: ~Collision();
public: virtual ~Collision();

/// \brief Assignment operator
/// \param[in] _other collision
4 changes: 1 addition & 3 deletions tpe/lib/src/CollisionDetector.cc
Original file line number Diff line number Diff line change
@@ -59,9 +59,7 @@ CollisionDetector::CollisionDetector()
}

//////////////////////////////////////////////////
CollisionDetector::~CollisionDetector()
{
}
CollisionDetector::~CollisionDetector() = default;

//////////////////////////////////////////////////
std::vector<Contact> CollisionDetector::CheckCollisions(
2 changes: 1 addition & 1 deletion tpe/lib/src/Entity.hh
Original file line number Diff line number Diff line change
@@ -60,7 +60,7 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE Entity
protected: explicit Entity(std::size_t _id);

/// \brief Destructor
public: ~Entity();
public: virtual ~Entity();

/// \brief Assignment operator
/// \param[in] _other Other entity to copy from
2 changes: 1 addition & 1 deletion tpe/lib/src/Link.hh
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE Link : public Entity
public: explicit Link(std::size_t _id);

/// \brief Destructor
public: ~Link() = default;
public: virtual ~Link() = default;

/// \brief Add a collision
/// \return Newly created Collision
2 changes: 1 addition & 1 deletion tpe/lib/src/Model.hh
Original file line number Diff line number Diff line change
@@ -42,7 +42,7 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE Model : public Entity
public: explicit Model(std::size_t _id);

/// \brief Destructor
public: ~Model();
public: virtual ~Model();

/// \brief Add a link
/// \return Newly created Link
35 changes: 0 additions & 35 deletions tpe/lib/src/Shape.cc
Original file line number Diff line number Diff line change
@@ -56,18 +56,6 @@ BoxShape::BoxShape() : Shape()
this->type = ShapeType::BOX;
}

//////////////////////////////////////////////////
BoxShape::BoxShape(const BoxShape &_other)
: Shape()
{
*this = _other;
}

//////////////////////////////////////////////////
BoxShape::~BoxShape()
{
}

//////////////////////////////////////////////////
Shape &BoxShape::operator=(const Shape &_other)
{
@@ -103,13 +91,6 @@ CylinderShape::CylinderShape() : Shape()
this->type = ShapeType::CYLINDER;
}

//////////////////////////////////////////////////
CylinderShape::CylinderShape(const CylinderShape &_other)
: Shape()
{
*this = _other;
}

//////////////////////////////////////////////////
Shape &CylinderShape::operator=(const Shape &_other)
{
@@ -158,13 +139,6 @@ SphereShape::SphereShape() : Shape()
this->type = ShapeType::SPHERE;
}

//////////////////////////////////////////////////
SphereShape::SphereShape(const SphereShape &_other)
: Shape()
{
*this = _other;
}

//////////////////////////////////////////////////
Shape &SphereShape::operator=(const Shape &_other)
{
@@ -199,13 +173,6 @@ MeshShape::MeshShape() : Shape()
this->type = ShapeType::MESH;
}

//////////////////////////////////////////////////
MeshShape::MeshShape(const MeshShape &_other)
: Shape()
{
*this = _other;
}

//////////////////////////////////////////////////
Shape &MeshShape::operator=(const Shape &_other)
{
@@ -245,5 +212,3 @@ void MeshShape::UpdateBoundingBox()
this->bbox = math::AxisAlignedBox(
this->scale * this->meshAABB.Min(), this->scale * this->meshAABB.Max());
}


26 changes: 5 additions & 21 deletions tpe/lib/src/Shape.hh
Original file line number Diff line number Diff line change
@@ -63,7 +63,7 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE Shape
public: Shape();

/// \brief Destructor
public: ~Shape() = default;
public: virtual ~Shape() = default;

/// \brief Get bounding box of shape
/// \return Shape's bounding box
@@ -92,12 +92,8 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE BoxShape : public Shape
/// \brief Constructor
public: BoxShape();

/// \brief Copy Constructor
/// \param[in] _other shape to copy from
public: BoxShape(const BoxShape &_other);

/// \brief Destructor
public: ~BoxShape();
public: virtual ~BoxShape() = default;

/// \brief Assignment operator
/// \param[in] _other shape to copy from
@@ -126,12 +122,8 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE CylinderShape : public Shape
/// \brief Constructor
public: CylinderShape();

/// \brief Copy Constructor
/// \param[in] _other shape to copy from
public: CylinderShape(const CylinderShape &_other);

/// \brief Destructor
public: ~CylinderShape() = default;
public: virtual ~CylinderShape() = default;

/// \brief Assignment operator
/// \param[in] _other shape to copy from
@@ -169,12 +161,8 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE SphereShape : public Shape
/// \brief Constructor
public: SphereShape();

/// \brief Copy Constructor
/// \param[in] _other shape to copy from
public: SphereShape(const SphereShape &_other);

/// \brief Destructor
public: ~SphereShape() = default;
public: virtual ~SphereShape() = default;

/// \brief Assignment operator
/// \param[in] _other shape to copy from
@@ -201,12 +189,8 @@ class IGNITION_PHYSICS_TPELIB_VISIBLE MeshShape : public Shape
/// \brief Constructor
public: MeshShape();

/// \brief Copy Constructor
/// \param[in] _other shape to copy from
public: MeshShape(const MeshShape &_other);

/// \brief Destructor
public: ~MeshShape() = default;
public: virtual ~MeshShape() = default;

/// \brief Assignment operator
/// \param[in] _other shape to copy from

0 comments on commit 9d5cc9a

Please sign in to comment.