LoginSignup
0
0

More than 3 years have passed since last update.

Toolプラグインの雛形

Posted at

rviz2プラグインの作り方 トップページへ

tool_template.hpp
#ifndef SAMPLE_RVIZ_PLUGINS_TOOL_TEMPLATE_HPP
#define SAMPLE_RVIZ_PLUGINS_TOOL_TEMPLATE_HPP

#include <rviz_common/tool.hpp>

namespace sample_rviz_plugins
{

class ToolTemplate : public rviz_common::Tool
{
public:
    ToolTemplate();
    virtual ~ToolTemplate();
    virtual void onInitialize();
    virtual void activate();
    virtual void deactivate();

protected:
private:
};

}
#endif // SAMPLE_RVIZ_PLUGINS_TOOL_TEMPLATE_HPP
tool_template.cpp
#include <rclcpp/rclcpp.hpp>
#include <rviz_common/tool.hpp>

#include "tool_template.hpp"

namespace sample_rviz_plugins
{

ToolTemplate::ToolTemplate()
    : rviz_common::Tool()
{
}

ToolTemplate::~ToolTemplate()
{
}

void ToolTemplate::onInitialize()
{
}

void ToolTemplate::activate()
{
}

void ToolTemplate::deactivate()
{
}

}

#include <pluginlib/class_list_macros.hpp>
PLUGINLIB_EXPORT_CLASS( sample_rviz_plugins::ToolTemplate, rviz_common::Tool )
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0