Room
Message type: map_manager/msg/Room
Description
Defines a room boundary and its vertical extent on a floor.
Fields
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier. |
name | string | Human-readable name. |
type | string | Entity type. |
boundary | geometry_msgs/Point[] | Polygon or point sequence defining the boundary. |
floor_height | float64 | Room floor height in meters. |
ceiling_height | float64 | Room ceiling height in meters. |
connected_rooms | string[] | Identifiers of rooms connected to this room. |
objects | string[] | List of semantic objects. |
Examples
Example 1
Bash
# Add an office room
ros2 service call ${MM}/add_room map_manager/srv/AddRoom \
"{floor_id: '1F',
room: {
id: 'room_101',
name: 'Office 101',
type: 'office',
boundary: [
{x: 0.0, y: 0.0, z: 0.0},
{x: 5.0, y: 0.0, z: 0.0},
{x: 5.0, y: 4.0, z: 0.0},
{x: 0.0, y: 4.0, z: 0.0}
],
floor_height: 0.0,
ceiling_height: 2.8,
connected_rooms: ['room_102', 'hallway_1'],
objects: ['desk_001', 'chair_001']
}
}"
Example 2
Python
from map_manager.msg import Room
from geometry_msgs.msg import Point
room = Room()
room.id = 'room_101'
room.name = 'Office 101'
room.type = 'office'
room.boundary = [
Point(x=0.0, y=0.0, z=0.0),
Point(x=5.0, y=0.0, z=0.0),
Point(x=5.0, y=4.0, z=0.0),
Point(x=0.0, y=4.0, z=0.0)
]
room.floor_height = 0.0
room.ceiling_height = 2.8
room.connected_rooms = ['room_102', 'hallway_1']
room.objects = ['desk_001', 'chair_001']