Skip to content

Commit

Permalink
Cast of "max_velocity" and "max_acceleration" values to double (#2803)
Browse files Browse the repository at this point in the history
Co-authored-by: Henning Kayser <[email protected]>
  • Loading branch information
JorgePRamos and henningkayser authored Jun 14, 2024
1 parent 40156e2 commit 5c11052
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ bool SRDFConfig::GeneratedJointLimits::writeYaml(YAML::Emitter& emitter)

// Output property
emitter << YAML::Key << "max_velocity";
emitter << YAML::Value << std::min(fabs(b.max_velocity_), fabs(b.min_velocity_));
emitter << YAML::Value << static_cast<double>(std::min(fabs(b.max_velocity_), fabs(b.min_velocity_)));

// Output property
emitter << YAML::Key << "has_acceleration_limits";
Expand All @@ -315,7 +315,7 @@ bool SRDFConfig::GeneratedJointLimits::writeYaml(YAML::Emitter& emitter)

// Output property
emitter << YAML::Key << "max_acceleration";
emitter << YAML::Value << std::min(fabs(b.max_acceleration_), fabs(b.min_acceleration_));
emitter << YAML::Value << static_cast<double>(std::min(fabs(b.max_acceleration_), fabs(b.min_acceleration_)));

emitter << YAML::EndMap;
}
Expand Down

0 comments on commit 5c11052

Please sign in to comment.