Skip to main content

tatolab-compositor

Video compositing nodes, built the way a third party builds one: an ordinary Python package that depends on tatolab-stream and on no engine crate. Its GPU work is one compute kernel built through create_compute_kernel, the surface every node is handed.

  • AlphaOverCompositor layers layer_0 to layer_7 back to front onto transparent black, in premultiplied alpha, and publishes the composite on video. It emits once per layer_0 frame, carrying that frame's timestamp. Every other layer contributes its newest frame, held until a newer one arrives; a layer that has never sent a frame is left out.
    • Config: width and height of the canvas, and layers, where entry N places layer_N with x, y and opacity. A layer with no entry sits at 0,0 at full opacity. Layers are drawn at their own size, never scaled.
    • Each arriving frame is copied by the engine into a texture the node owns, so a held layer never holds its producer's frame. Input frames must be single-plane RGBA the engine copy accepts.

A lower third over a camera is three nodes:

from tatolab.compositor import AlphaOverCompositor

compositor = stream_builder.add(
    AlphaOverCompositor,
    config={"width": 1920, "height": 1080, "layers": [{}, {"x": 80, "y": 860}]},
)
stream_builder.connect(camera.output("video"), compositor.input("layer_0"))
stream_builder.connect(lower_third.output("video"), compositor.input("layer_1"))

Run it

streams/camera-with-two-overlays is a camera with two test-pattern overlays, encoded and exposed, with the camera wheel's latency probe after the compositor reporting the composite's frame rate. With this machine's runtime running and a camera attached:

cd streams/camera-with-two-overlays
tatolab dev

Check it

uv venv --python 3.12 .venv && VIRTUAL_ENV=.venv uv pip install ../../sdk/tatolab-stream -e . pytest
.venv/bin/pytest tests && uvx pyright@1.1.411

The pixel tests run on a runtime, in the integration suite's test_alpha_over_compositor.py.

Metadata

Release files for tatolab-compositor 0.68.32

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for tatolab-compositor 0.68.32
File Interpreter ABI Platform Actions
tatolab_compositor-0.68.32-py3-none-any.whl Python 3 none any Details for tatolab_compositor-0.68.32-py3-none-any.whl

Release files / tatolab_compositor-0.68.32-py3-none-any.whl

Download URL tatolab_compositor-0.68.32-py3-none-any.whl
Size 10.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
19463bdd172b1d6b58da2ad17de771cd1b87ea8f2504b9a30d7d451074dd599a
BLAKE2b-256 checksum
How to use checksums
4095114d74be87c9698d79ac4ba47483dec7d25e576744f7b6ab51561e6be271
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for tatolab-compositor 0.68.32

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page