Skip to main content

vexy-stax

Documentation: https://vexy.dev/vexy-stax-py/

Render a deck of layered PNG slides as 3D glass plates — in two views and the transitions between them — from a single shared JSON scene format. This is the offline Python package; a browser sibling (vexy-stax-js) consumes the same scene format. See the repo-level SPEC.md for the binding contract.

This package implements the scene model, geometry math, CLI, and three fully functional render backends: Blender, pygfx, and Playwright.

Install

pip install vexy-stax          # published on PyPI as `vexy-stax`

Or, for a checkout you want to hack on:

uv venv --python 3.12 && uv sync

Concepts

  • A scene is an ordered list of slides (back-to-front; index 0 is farthest from the camera) plus camera, floor, and transition settings.
  • Two views: expanded (angled, plates spaced by gap, captions on) and compact (head-on, plates collapsed to MIN_GAP ≈ 3 pt).
  • A transition morphs between the views (expand, collapse, expand_collapse, collapse_expand), interpolating camera, spacing, and per-slide opacity with a shared easing curve.

CLI

vexy-stax dir2scene assets/ --out scene.json             # generate scene JSON from directory
vexy-stax render    scene.json --view expanded --engine pygfx   --out beauty.png
vexy-stax render    scene.json --view compact  --engine blender --out stack.png
vexy-stax video     scene.json --engine blender --out morph.mp4
vexy-stax overlay   scene.json --out flat.png          # pure-Pillow flat composite
vexy-stax engines                                      # list available engines

Defaults: still ⇒ pygfx, video ⇒ blender. A missing/unimplemented engine fails with an actionable message, not a crash.

Library

from vexy_stax.scene import load_scene
from vexy_stax import geometry as g

scene = load_scene("scene.json")          # validates + resolves slide paths
plan = g.frame_plan(scene)                 # per-frame camera/spacing/opacity
pose = g.expanded_camera(scene)            # CameraPose dataclass

vexy_stax.scene is a strict pydantic v2 model (extra="forbid" everywhere — unknown fields fail loud at the boundary). vexy_stax.geometry holds the pure, engine-agnostic view math (SPEC.md §3), mirrored by the JS geometry.js against shared fixture vectors.

Layout

src/vexy_stax/
├── scene.py        # pydantic v2 scene model + loader
├── geometry.py     # §3 camera/spacing/opacity math (pure, engine-agnostic)
├── engines/        # base.py protocol + registry; blender, pygfx, and playwright renderers
├── images.py       # Composites 2D flat preview overlays using Pillow
├── juicy.py        # Matches colors between 3D renders and 2D overlays
└── cli.py          # fire + rich CLI

Test

uv run pytest -q

License

MIT.

Metadata

Release files for vexy-stax 3.1.8

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

Source distribution (sdist)

Source distribution for vexy-stax 3.1.8
File Size Uploaded
vexy_stax-3.1.8.tar.gz 580.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for vexy-stax 3.1.8
File Interpreter ABI Platform
vexy_stax-3.1.8-py3-none-any.whl Python 3 none any Details

Total release size: 693.5 kB

Release files / vexy_stax-3.1.8.tar.gz

Download URL vexy_stax-3.1.8.tar.gz
Size 580.4 kB
Tags Source
SHA-256 checksum
How to use checksums
91edadc58b1a1cfea9a65e7fab6e02c042ba7a993b62f258c6624c002f5d35c7
BLAKE2b-256 checksum
How to use checksums
595ee7a747ec78149da5129647e4ed3f27952346b10884602f21ba564497255f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / vexy_stax-3.1.8-py3-none-any.whl

Download URL vexy_stax-3.1.8-py3-none-any.whl
Size 113.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c11eea211c053e037c52c1d6d1f41d302c11fa0f8a6f580655a04b33a9e48bf4
BLAKE2b-256 checksum
How to use checksums
a73bb7d017364b9ff6e5ec42258cb6e9b1edc9f9adea9da8f2039e7cb2c4caff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

This release

3.1.8 This release

2 release files

3.1.6

2 release files

3.1.5

2 release files

3.1.4

2 release files

3.1.2

2 release files

3.1.1

2 release files

3.0.3

2 release files

3.0.0

2 release files

0.1.0

2 release files

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