Metadata-Version: 2.3
Name: websocket-proxy
Version: 0.6.0
Summary: Foxglove WebSocket proxy with message transformations
Keywords: websocket,foxglove,robotics,ros,ros2,proxy,compression
Author: Marko Bausch
License: GPL-3.0
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Internet
Classifier: Topic :: Scientific/Engineering
Classifier: Typing :: Typed
Requires-Dist: mcap-codec-support[video,pointcloud]
Requires-Dist: websockets>=15.0.1
Requires-Dist: typing-extensions>=4.12.2
Requires-Dist: mcap-ros2-support-fast
Requires-Dist: robo-ws-bridge
Requires-Dist: rich>=14.2.0
Requires-Python: >=3.10
Project-URL: Homepage, https://github.com/mrkbac/robotic-tools
Project-URL: Issues, https://github.com/mrkbac/robotic-tools/issues
Project-URL: Repository, https://github.com/mrkbac/robotic-tools
Description-Content-Type: text/markdown

# websocket-proxy

A proxy for [Foxglove Bridge](https://github.com/foxglove/foxglove-sdk/tree/main/ros/src/foxglove_bridge) that converts messages just-in-time and forwards them via the Foxglove Bridge protocol.

## Installation

```bash
# Run directly without installing
uvx --from websocket-proxy bridge ws://localhost:8765

# Or add to your project
uv add websocket-proxy
```

## Features

- Converts `sensor_msgs/msg/CompressedImage` and `sensor_msgs/msg/Image` to `foxglove_msgs/msg/CompressedVideo`
  - Using ffmpeg: h264, h265, vp9, av1
  - Downscaling support
- Converts `sensor_msgs/msg/PointCloud2` to `point_cloud_interfaces/msg/CompressedPointCloud2` using [cloudini](https://github.com/facontidavide/cloudini)
  - Downsampling support (dropping random points, voxelize grid)
- Throttling support for all topics
- Prevents flooding traffic by awaiting Ping/Pong

## Usage

```bash
bridge <source-ws>
```

This starts the bridge connecting to `<source-ws>` and opens the proxy at `ws://0.0.0.0:8766`.

Default settings:
- Image downsampling to HD and h264 compression
- Cloudini point cloud compression
- Throttling to 1Hz
