Drake
car_vis.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 #include <vector>
5 
6 #include "drake/lcmt_viewer_link_data.hpp"
8 
9 namespace drake {
10 namespace automotive {
11 
20 template <typename T>
21 class CarVis {
22  public:
24 
25 
26  CarVis(int id, const std::string& name) : id_(id), name_(name) {}
34 
35  virtual ~CarVis() {}
36 
38  virtual const std::vector<lcmt_viewer_link_data>& GetVisElements() const = 0;
39 
47  const Isometry3<T>& X_WM) const = 0;
48 
50  int id() const { return id_; }
51 
53  const std::string& name() const { return name_; }
54 
56  int num_poses() const;
57 
58  private:
59  const int id_;
60  const std::string name_;
61 };
62 
63 } // namespace automotive
64 } // namespace drake
Eigen::Transform< Scalar, 3, Eigen::Isometry > Isometry3
An Isometry templated on scalar type.
Definition: eigen_types.h:106
virtual systems::rendering::PoseBundle< T > CalcPoses(const Isometry3< T > &X_WM) const =0
Computes and returns the poses of the bodies that constitute the vehicle&#39;s visualization.
CarVis(const CarVis &)=delete
Definition: automotive_demo.cc:88
PoseBundle is a container for a set of poses, represented by an Isometry3, and corresponding velociti...
Definition: pose_bundle.h:40
int id() const
Returns the ID that was supplied to the constructor.
Definition: car_vis.h:50
int num_poses() const
Returns the number of visualization geometry poses.
Definition: car_vis.cc:7
CarVis is a base class that provides visualization geometries and their poses.
Definition: car_vis.h:21
const std::string & name() const
Returns the name that was supplied to the constructor.
Definition: car_vis.h:53
virtual const std::vector< lcmt_viewer_link_data > & GetVisElements() const =0
Returns the visualization elements.
virtual ~CarVis()
Definition: car_vis.h:35
#define DRAKE_NO_COPY_NO_MOVE_NO_ASSIGN(Classname)
DRAKE_NO_COPY_NO_MOVE_NO_ASSIGN deletes the special member functions for copy-construction, copy-assignment, move-construction, and move-assignment.
Definition: drake_copyable.h:35