constants.h
Go to the documentation of this file.
1
#pragma once
2
3
// PCL
4
#include <pcl/point_types.h>
5
6
// core
7
#include <
ArmarXCore/core/exceptions/LocalException.h
>
8
9
// memory
10
#include <
RobotAPI/libraries/armem/core/MemoryID.h
>
11
12
namespace
visionx::armem::pointcloud
13
{
14
const
constexpr
char
*
POINTXYZ_CORE_SEGMENT_NAME
=
"PointCloudXYZ"
;
15
const
constexpr
char
*
POINTXYZL_CORE_SEGMENT_NAME
=
"PointCloudXYZL"
;
16
const
constexpr
char
*
POINTXYZRGBA_CORE_SEGMENT_NAME
=
"PointCloudXYZRGBA"
;
17
const
constexpr
char
*
POINTXYZRGBL_CORE_SEGMENT_NAME
=
"PointCloudXYZRGBL"
;
18
19
const
constexpr
char
*
ENTITY_NAME
=
"PointCloud"
;
20
21
template
<
class
Po
int
T>
22
inline
std::string
23
GetCoreSegmentNameFor
()
24
{
25
if
(
std::is_same<PointT, pcl::PointXYZ>::value
)
26
{
27
return
POINTXYZ_CORE_SEGMENT_NAME
;
28
}
29
if
(
std::is_same<PointT, pcl::PointXYZL>::value
)
30
{
31
return
POINTXYZL_CORE_SEGMENT_NAME
;
32
}
33
if
(
std::is_same<PointT, pcl::PointXYZRGBA>::value
)
34
{
35
return
POINTXYZRGBA_CORE_SEGMENT_NAME
;
36
}
37
if
(
std::is_same<PointT, pcl::PointXYZRGBL>::value
)
38
{
39
return
POINTXYZRGBL_CORE_SEGMENT_NAME
;
40
}
41
throw
armarx::LocalException(
"Could not map a pcl::PointT to a known core segment."
);
42
}
43
}
// namespace visionx::armem::pointcloud
LocalException.h
MemoryID.h
visionx::armem::pointcloud::POINTXYZRGBL_CORE_SEGMENT_NAME
const constexpr char * POINTXYZRGBL_CORE_SEGMENT_NAME
Definition:
constants.h:17
visionx::armem::pointcloud::ENTITY_NAME
const constexpr char * ENTITY_NAME
Definition:
constants.h:19
cxxopts::value
std::shared_ptr< Value > value()
Definition:
cxxopts.hpp:926
visionx::armem::pointcloud::GetCoreSegmentNameFor
std::string GetCoreSegmentNameFor()
Definition:
constants.h:23
visionx::armem::pointcloud
Definition:
constants.cpp:3
visionx::armem::pointcloud::POINTXYZL_CORE_SEGMENT_NAME
const constexpr char * POINTXYZL_CORE_SEGMENT_NAME
Definition:
constants.h:15
visionx::armem::pointcloud::POINTXYZRGBA_CORE_SEGMENT_NAME
const constexpr char * POINTXYZRGBA_CORE_SEGMENT_NAME
Definition:
constants.h:16
visionx::armem::pointcloud::POINTXYZ_CORE_SEGMENT_NAME
const constexpr char * POINTXYZ_CORE_SEGMENT_NAME
Definition:
constants.h:14
VisionX
libraries
armem
vision
pointcloud
client
constants.h
Generated on Sat Oct 12 2024 09:14:08 for armarx_documentation by
1.8.17