Apollo 10.0
自动驾驶开放平台
apollo::perception::camera::CarPose类 参考

#include <pose.h>

apollo::perception::camera::CarPose 的协作图:

Public 类型

template<typename T , class EigenType >
using EigenMap = apollo::common::EigenMap< T, EigenType >
 

Public 成员函数

 CarPose ()=default
 
 ~CarPose ()=default
 
bool Init (double ts, const Eigen::Matrix4d &pose)
 
const Eigen::Matrix4d getCarPose () const
 
const Eigen::Vector3d getCarPosition () const
 
void ClearCameraPose (const std::string &camera_name)
 
void SetCameraPose (const std::string &camera_name, const Eigen::Matrix4d &c2w_pose)
 
bool GetCameraPose (const std::string &camera_name, Eigen::Matrix4d *c2w_pose) const
 
void setTimestamp (double ts)
 
double getTimestamp () const
 

Public 属性

Eigen::Matrix4d pose_
 
EigenMap< std::string, Eigen::Matrix4d > c2w_poses_
 
double timestamp_
 

友元

std::ostream & operator<< (std::ostream &os, const CarPose &)
 

详细描述

在文件 pose.h30 行定义.

成员类型定义说明

◆ EigenMap

template<typename T , class EigenType >
using apollo::perception::camera::CarPose::EigenMap = apollo::common::EigenMap<T, EigenType>

在文件 pose.h35 行定义.

构造及析构函数说明

◆ CarPose()

apollo::perception::camera::CarPose::CarPose ( )
default

◆ ~CarPose()

apollo::perception::camera::CarPose::~CarPose ( )
default

成员函数说明

◆ ClearCameraPose()

void apollo::perception::camera::CarPose::ClearCameraPose ( const std::string &  camera_name)

在文件 pose.cc64 行定义.

64 {
65 auto it = c2w_poses_.find(camera_name);
66 if (it != c2w_poses_.end()) {
67 c2w_poses_.erase(it);
68 }
69}
EigenMap< std::string, Eigen::Matrix4d > c2w_poses_
Definition pose.h:57

◆ GetCameraPose()

bool apollo::perception::camera::CarPose::GetCameraPose ( const std::string &  camera_name,
Eigen::Matrix4d *  c2w_pose 
) const

在文件 pose.cc46 行定义.

47 {
48 if (c2w_pose == nullptr) {
49 AERROR << "c2w_pose is not available";
50 return false;
51 }
52 if (c2w_poses_.find(camera_name) == c2w_poses_.end()) {
53 return false;
54 }
55 *c2w_pose = c2w_poses_.at(camera_name);
56
57 return true;
58}
#define AERROR
Definition log.h:44

◆ getCarPose()

const Eigen::Matrix4d apollo::perception::camera::CarPose::getCarPose ( ) const

在文件 pose.cc30 行定义.

30{ return pose_; }

◆ getCarPosition()

const Eigen::Vector3d apollo::perception::camera::CarPose::getCarPosition ( ) const

在文件 pose.cc32 行定义.

32 {
33 Eigen::Vector3d p;
34 p[0] = pose_(0, 3);
35 p[1] = pose_(1, 3);
36 p[2] = pose_(2, 3);
37
38 return p;
39}

◆ getTimestamp()

double apollo::perception::camera::CarPose::getTimestamp ( ) const
inline

在文件 pose.h53 行定义.

53{ return timestamp_; }

◆ Init()

bool apollo::perception::camera::CarPose::Init ( double  ts,
const Eigen::Matrix4d &  pose 
)

在文件 pose.cc24 行定义.

24 {
25 timestamp_ = ts;
26 pose_ = pose;
27 return true;
28}

◆ SetCameraPose()

void apollo::perception::camera::CarPose::SetCameraPose ( const std::string &  camera_name,
const Eigen::Matrix4d &  c2w_pose 
)

在文件 pose.cc41 行定义.

42 {
43 c2w_poses_[camera_name] = c2w_pose;
44}

◆ setTimestamp()

void apollo::perception::camera::CarPose::setTimestamp ( double  ts)
inline

在文件 pose.h52 行定义.

52{ timestamp_ = ts; }

友元及相关函数文档

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const CarPose  
)
friend

在文件 pose.cc60 行定义.

60 {
61 os << pose.pose_;
62 return os;
63}

类成员变量说明

◆ c2w_poses_

EigenMap<std::string, Eigen::Matrix4d> apollo::perception::camera::CarPose::c2w_poses_

在文件 pose.h57 行定义.

◆ pose_

Eigen::Matrix4d apollo::perception::camera::CarPose::pose_

在文件 pose.h55 行定义.

◆ timestamp_

double apollo::perception::camera::CarPose::timestamp_

在文件 pose.h58 行定义.


该类的文档由以下文件生成: