Skip to content

Rendering

Visualization and rendering utilities for soft robot systems.

Overview

The rendering module provides a class-based architecture for visualizing soft robots. All renderers inherit from a common base class BaseSoftRobotRenderer which provides cached forward kinematics and a unified interface.

The Matplotlib, Open3D, and Viser samples show the same three-segment spatial PCS configuration with the paper color theme, a dark base, and a base-aligned ground plane. The OpenCV sample uses its three-segment planar counterpart with the same dark-base and warm-backbone styling.

System-specific renderer designs are documented alongside their robots: the Planar HSA OpenCV renderer, I-SUPPORT Viser renderer, and UMArm Viser renderer.

Choosing a Renderer

Renderer Best For Strengths Limitations
MatplotlibRenderer Static plots, notebooks, debugging Works with any robot, easy to embed Limited interactivity, slower animations
Open3DRenderer Interactive 3D inspection Rich camera controls, headless capture Requires Open3D, 3D only
ViserRenderer Live demos, web-based visualization Browser UI, live streaming, multi-robot Requires web server, 3D only
OpenCVPlanarRenderer Fast 2D animations, video export Lightweight, fast output Planar robots only
OpenCVPlanarHSARenderer PlanarHSA-specific visuals HSA-specific geometry PlanarHSA only

Documentation

Renderer API

Complete API reference for all renderer classes:

  • BaseSoftRobotRenderer - Abstract base class
  • MatplotlibRenderer - Matplotlib-based visualization
  • Open3DRenderer - Open3D-based 3D visualization
  • ViserRenderer - Web-based visualization
  • OpenCVPlanarRenderer - OpenCV-based 2D visualization
  • OpenCVPlanarHSARenderer - HSA-specific visualization

Shared Configuration

Settings shared by multiple renderer backends:

  • CameraConfig - Camera positioning and field of view
  • Robot base, base-plate, and ground-plane behavior
  • Multi-robot layouts and spacing
  • Recording and video encoding
  • RendererColorConfig - Color configuration hierarchy
  • BackboneColorConfig - Backbone-specific colors
  • Built-in color palettes and themes

Quick Start

All renderers accept a robot model at construction and expose a single-frame entry point. For example:

from soromox.rendering import MatplotlibRenderer

renderer = MatplotlibRenderer(robot, num_points=50)
renderer.show(q)

Choose another backend from the table above, then follow its API reference for interactive playback, live mode, or video capture.