CARLA
载入中...
搜索中...
未找到
LibCarla
source
carla
rpc
ActorId.h
浏览该文件的文档.
1
// Copyright (c) 2017 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
// 这是一个头文件保护,防止头文件被重复包含
8
#pragma once
9
10
// 包含标准的C++整数类型相关的头文件,这里后续可能会用到像uint32_t这样的类型定义
11
#include <cstdint>
12
13
// 定义了carla命名空间,通常用于将和Carla相关的代码组织在一个逻辑范围内,避免命名冲突
14
namespace
carla
{
15
// 在carla命名空间内,又定义了rpc子命名空间,可能用于存放和远程过程调用(RPC)相关的类型、函数等
16
namespace
rpc {
17
// 使用类型别名(typedef的替代语法)将uint32_t类型重命名为ActorId,
18
// 这样在rpc命名空间内,ActorId就代表了一个32位无符号整数类型,
19
// 可能用于标识某个Actor(比如在模拟环境中的某个对象,像车辆、行人等)的唯一ID
20
using
ActorId
= uint32_t;
21
}
// namespace rpc
22
23
// 这里再次使用类型别名,将rpc命名空间内定义的ActorId类型引入到carla命名空间下,
24
// 使得在carla命名空间的其他地方可以直接使用ActorId这个类型名来表示对应的32位无符号整数类型,
25
// 方便代码中统一使用该类型来处理与Actor相关的标识等操作。
26
using
ActorId
=
rpc::ActorId
;
27
}
// namespace carla
carla::rpc::ActorId
uint32_t ActorId
Definition
ActorId.h:20
carla
CARLA模拟器的主命名空间。
Definition
Carla.cpp:139
carla::ActorId
rpc::ActorId ActorId
Definition
ActorId.h:26
制作者
1.10.0