Skip to content

nvblox

Practical

nvblox is NVIDIA’s GPU-accelerated library for real-time 3D scene reconstruction. It builds volumetric representations from depth cameras and 3D LiDAR, outputting meshes, distance fields, and costmaps for robot navigation and manipulation.

Prerequisites

Why nvblox Matters

  • GPU acceleration: Up to 177x faster TSDF integration vs CPU implementations
  • Real-time mapping: Updates 3D reconstructions as sensor data streams in
  • Nav2 integration: Direct costmap layer plugin for navigation
  • Dynamic environments: Separates static scenes from moving objects/people
  • Multi-sensor fusion: Combines depth cameras and LiDAR simultaneously

Architecture

┌─────────────────────────────────────────────────────────────────┐
│ nvblox Pipeline │
├─────────────────────────────────────────────────────────────────┤
│ │
│ Input Processing Output │
│ ───── ────────── ────── │
│ │
│ ┌──────────┐ ┌──────────────────┐ ┌─────────────┐ │
│ │ RGB-D │──┐ │ Mapper │ │ Mesh │ │
│ │ Camera │ │ │ ┌────────────┐ │────►│ (RViz) │ │
│ └──────────┘ │ │ │ TSDF │ │ └─────────────┘ │
│ ├─────►│ │ Integrator │ │ │
│ ┌──────────┐ │ │ └────────────┘ │ ┌─────────────┐ │
│ │ 3D │──┤ │ ┌────────────┐ │────►│ ESDF │ │
│ │ LiDAR │ │ │ │ ESDF │ │ │ (cuMotion) │ │
│ └──────────┘ │ │ │ Integrator │ │ └─────────────┘ │
│ │ │ └────────────┘ │ │
│ ┌──────────┐ │ │ ┌────────────┐ │ ┌─────────────┐ │
│ │ Pose │──┘ │ │ Mesh │ │────►│ 2D Costmap │ │
│ │ (SLAM) │ │ │ Generator │ │ │ (Nav2) │ │
│ └──────────┘ │ └────────────┘ │ └─────────────┘ │
│ └────────┬─────────┘ │
│ │ │
│ ┌────────▼────────┐ │
│ │ LayerCake │ │
│ │ (GPU Memory) │ │
│ │ TSDF│ESDF│Color │ │
│ └─────────────────┘ │
│ │
└─────────────────────────────────────────────────────────────────┘

Core Concepts

TSDF (Truncated Signed Distance Function)

Stores the signed distance to the nearest surface at each voxel:

Surface
◄───────────│───────────►
Negative │ Positive
(inside) │ (outside)
─────┬─────┬─────┼─────┬─────┬─────
-d -d/2 0 d/2 d ← TSDF values (truncated)
  • Primary representation for high-quality surface reconstruction
  • Default resolution: 5cm voxels (configurable)
  • Incrementally updated as new depth data arrives

ESDF (Euclidean Signed Distance Function)

Full distance field for path planning and collision checking:

  • Provides distance to nearest obstacle at any point in space
  • Used by Nav2 for costmap generation
  • Used by cuMotion for manipulation collision avoidance
  • GPU-accelerated incremental computation

LayerCake Architecture

Multiple co-registered volumetric layers in GPU memory:

LayerPurpose
TSDFDistance to surfaces
ESDFEuclidean distances for planning
ColorRGB texture from cameras
OccupancyDynamic object tracking
MeshExtracted surface geometry

Operating Modes

Default mode assuming the environment is unchanging:

Terminal window
ros2 launch nvblox_examples_bringup realsense_example.launch.py

All sensor data integrates into a single TSDF layer.

nvblox provides a direct costmap plugin for Nav2:

local_costmap:
local_costmap:
ros__parameters:
global_frame: odom
robot_base_frame: base_link
rolling_window: true
plugins: ["nvblox_layer", "inflation_layer"]
nvblox_layer:
plugin: "nvblox::NvbloxCostmapLayer"
inflation_layer:
plugin: "nav2_costmap_2d::InflationLayer"
inflation_radius: 0.55

The pipeline slices the 3D ESDF into a 2D costmap:

Depth Camera → nvblox (ESDF) → 2D Slice → Nav2 Costmap → Path Planning

Key Parameters

nvblox_node:
ros__parameters:
# Voxel resolution (default: 5cm)
voxel_size: 0.05
# ESDF settings
esdf: true
esdf_2d: true
esdf_integrator_max_distance_m: 10.0
# Height slice for costmap
slice_height: 1.0
min_height: 0.0
max_height: 1.0
# Integration rate
max_tsdf_update_hz: 10.0

Multi-Sensor Support

nvblox can fuse data from multiple sensors simultaneously:

Terminal window
# LiDAR + 3 cameras
ros2 launch nvblox_examples_bringup isaac_sim_example.launch.py \
lidar:=True \
num_cameras:=3
  • Up to 4 simultaneous RealSense cameras (Jetson AGX Orin)
  • 3D LiDAR integration
  • Pose input from cuVSLAM or other SLAM systems

Package Structure

PackagePurpose
isaac_ros_nvbloxCore ROS 2 integration
nvblox_nav2Nav2 costmap layer plugin
nvblox_rviz_pluginRViz mesh visualization
nvblox_msgsCustom message definitions
nvblox_examples_bringupLaunch files for tutorials

Performance

Operationnvblox (GPU)voxblox (CPU)Speedup
TSDF IntegrationFastBaseline177x
ESDF ComputationFastBaseline31x
  • Runs at <7ms per LiDAR scan (5cm resolution, 25m range)
  • Real-time mesh updates streamed to RViz

Learn More

Sources