Skip to content

Commit

Permalink
Remove input parameter from service
Browse files Browse the repository at this point in the history
Signed-off-by: Steven Peters <scpeters@openrobotics.org>
  • Loading branch information
scpeters committed Jul 22, 2021
1 parent 2d4d4df commit 18092a2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
3 changes: 1 addition & 2 deletions gazebo/physics/World.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3359,8 +3359,7 @@ bool World::PluginInfoService(const ignition::msgs::StringMsg &_req,
}

//////////////////////////////////////////////////
bool World::ShadowCasterService(const ignition::msgs::StringMsg &_req,
ignition::msgs::StringMsg &_res)
bool World::ShadowCasterService(ignition::msgs::StringMsg &_res)
{
_res.set_data(this->dataPtr->shadowCasterMaterialName.c_str());
return true;
Expand Down
4 changes: 1 addition & 3 deletions gazebo/physics/World.hh
Original file line number Diff line number Diff line change
Expand Up @@ -652,11 +652,9 @@ namespace gazebo
ignition::msgs::Plugin_V &_plugins);

/// \brief Callback for "<this_name>/shadow_caster_material_name" service.
/// \param[in] _request Request containing plugin URI.
/// \param[out] _response Message containing shadow caster material name
/// \return True if the info was successfully obtained.
private: bool ShadowCasterService(const ignition::msgs::StringMsg &_request,
ignition::msgs::StringMsg &_response);
private: bool ShadowCasterService(ignition::msgs::StringMsg &_response);

/// \internal
/// \brief Private data pointer.
Expand Down
3 changes: 1 addition & 2 deletions gazebo/rendering/Scene.cc
Original file line number Diff line number Diff line change
Expand Up @@ -209,13 +209,12 @@ Scene::Scene(const std::string &_name, const bool _enableVisualizations,

// Get shadow caster material name from physics::World
ignition::transport::Node node;
ignition::msgs::StringMsg req;
ignition::msgs::StringMsg rep;
const std::string serviceName = "/shadow_caster_material_name";
bool result;
unsigned int timeout = 5000;
bool executed = node.Request(serviceName,
req, timeout, rep, result);
timeout, rep, result);
if (executed)
{
if (result)
Expand Down

0 comments on commit 18092a2

Please # to comment.