gitmyhub

Rusty-Tuber

Rust ★ 1 updated 1mo ago

PNG-Tuber software written in rust. highly customizeable

A Rust-based PNG avatar tool for streamers that reacts to your microphone and outputs a virtual webcam that OBS, Zoom, and Discord treat as a normal camera.

Rustv4l2loopbackALSAWebSocketREST APIsetup: moderatecomplexity 3/5

Rusty-Tuber is a PNG avatar animation tool for streamers and virtual content creators. You supply a set of layered PNG images for a character's body, mouth states, and eye expressions, and the program drives them in real time from your microphone volume. As you speak, the mouth layer switches between four states (closed, partial, medium, and open) based on loudness. Eye expressions, blinking, and custom emotion sets can be triggered from a browser-based control panel or via keyboard shortcuts.

Rather than displaying the avatar in a separate window you add to your stream, Rusty-Tuber composites all the layers into a virtual webcam. Any application that reads a camera, including OBS, Zoom, Discord, and browsers, picks it up as a normal camera input. In OBS you add a chroma key filter to remove the background color and the avatar appears transparent on your scene. The virtual webcam runs at 30 frames per second while you are talking and drops to about 8 frames per second during silence to save CPU.

A built-in web panel at localhost:8080 lets you trigger emotion sets, force mouth or eye states, tune the microphone sensitivity thresholds, and adjust how fast the mouth opens and closes. The panel works on a phone or tablet on the same network, so it can function like a wireless controller during a live stream. There is also a REST API and a WebSocket endpoint for external automation and hardware hotkeys.

The application compiles to a single Rust binary. The web interface is embedded inside it, so the only external files are your character's PNG images. On Linux it requires the v4l2loopback kernel module for the virtual webcam and the ALSA audio development headers to compile. macOS and Windows use the operating system's built-in audio and need no extra packages.

Character art is organized as folders of transparent PNGs with specific names for each mouth and eye state. A placeholder macaw character ships with the repository. Assets are loaded once at startup, so you restart the server after adding new layers or emotion folders.

Where it fits