Skip to content

Commit

Permalink
Changed meshScale param to const ref, updated function docs
Browse files Browse the repository at this point in the history
Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
  • Loading branch information
jasmeet0915 committed Sep 26, 2023
1 parent ffd1c41 commit d892b53
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/MeshInertiaCalculator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ using namespace sim;

//////////////////////////////////////////////////
void MeshInertiaCalculator::GetMeshTriangles(
std::vector<Triangle>& _triangles,
gz::math::Vector3d _meshScale,
std::vector<Triangle> &_triangles,
const gz::math::Vector3d &_meshScale,
const gz::common::Mesh* _mesh)
{
// Get the vertices & indices of the mesh
Expand Down
6 changes: 4 additions & 2 deletions src/MeshInertiaCalculator.hh
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,12 @@ namespace gz
/// \param[out] _triangles A vector to hold all the Triangle
/// instances obtained
/// from the vertices & indices of the mesh
/// \param[in] _meshScale A vector with the scaling factor
/// of all the 3 axes
/// \param[in] _mesh Mesh object
public: void GetMeshTriangles(
std::vector<Triangle>& _triangles,
gz::math::Vector3d _meshScale,
std::vector<Triangle> &_triangles,
const gz::math::Vector3d &_meshScale,
const gz::common::Mesh* _mesh);

/// \brief Function to calculate the centroid of the mesh. Since
Expand Down

0 comments on commit d892b53

Please sign in to comment.