CARLA
载入中...
搜索中...
未找到
LibCarla
source
carla
rpc
MapLayer.h
浏览该文件的文档.
1
// Copyright (c) 2020 Computer Vision Center (CVC) at the Universitat Autonoma
2
// de Barcelona (UAB).
3
//
4
// This work is licensed under the terms of the MIT license.
5
// For a copy, see <https://opensource.org/licenses/MIT>.
6
7
#pragma once
8
9
#include "
carla/MsgPack.h
"
10
11
#include <cstdint>
12
13
namespace
carla
{
14
namespace
rpc {
15
16
// 定义一个类型别名 MapLayerType,它是一个 16 位无符号整数
17
using
MapLayerType
= uint16_t;
18
19
// 定义一个枚举类 MapLayer,它继承自 MapLayerType
20
enum class
MapLayer
:
MapLayerType
21
{
22
// 没有任何层
23
None
= 0,
24
// 表示建筑物层
25
Buildings
= 0x1,
26
// 表示贴花层
27
Decals
= 0x1 << 1,
28
// 表示植被层
29
Foliage
= 0x1 << 2,
30
// 表示地面层
31
Ground
= 0x1 << 3,
32
// 表示停放的车辆层
33
ParkedVehicles
= 0x1 << 4,
34
// 表示粒子层
35
Particles
= 0x1 << 5,
36
// 表示道具层
37
Props
= 0x1 << 6,
38
// 表示路灯层
39
StreetLights
= 0x1 << 7,
40
// 表示墙壁层
41
Walls
= 0x1 << 8,
42
// 表示所有层
43
All
= 0xFFFF,
44
};
45
46
// 函数声明:将 MapLayer 枚举值转换为字符串
47
std::string
MapLayerToString
(
MapLayer
MapLayerValue);
48
49
}
// namespace rpc
50
}
// namespace carla
51
52
// 定义一个用于序列化和反序列化 MapLayer 枚举的宏
53
MSGPACK_ADD_ENUM
(
carla::rpc::MapLayer
);
MSGPACK_ADD_ENUM
MSGPACK_ADD_ENUM(carla::rpc::MapLayer)
MsgPack.h
carla::rpc::MapLayer
MapLayer
Definition
MapLayer.h:21
carla::rpc::MapLayer::Walls
@ Walls
carla::rpc::MapLayer::Ground
@ Ground
carla::rpc::MapLayer::None
@ None
carla::rpc::MapLayer::ParkedVehicles
@ ParkedVehicles
carla::rpc::MapLayer::StreetLights
@ StreetLights
carla::rpc::MapLayer::Props
@ Props
carla::rpc::MapLayer::Buildings
@ Buildings
carla::rpc::MapLayer::Particles
@ Particles
carla::rpc::MapLayer::All
@ All
carla::rpc::MapLayer::Foliage
@ Foliage
carla::rpc::MapLayer::Decals
@ Decals
carla::rpc::MapLayerToString
std::string MapLayerToString(MapLayer MapLayerValue)
Definition
MapLayer.cpp:12
carla::rpc::MapLayerType
uint16_t MapLayerType
Definition
MapLayer.h:17
carla
CARLA模拟器的主命名空间。
Definition
Carla.cpp:139
制作者
1.10.0