napari-volume-spin
Imaris-style continuous 3D spin animation controls for napari, with looping GIF/MP4 export
This napari plugin was generated with copier using the napari-plugin-template.
Demo
Features
napari-volume-spin adds a Volume Spin Controls dock widget with three
tabs that mimics Imaris's continuous 3D rotation animation:
Spin Controls tab
- Play / Pause a continuous spin of the 3D camera around the currently viewed volume.
- Choose the screen-relative rotation axis: X (pitch), Y (roll), or Z (yaw).
- Adjust spin speed (0.05–1.0 degrees/frame) via a linked slider and spin box.
Export tab
- Export a looping GIF or MP4 of the current axis/speed settings: a full 360° rotation is captured automatically so the animation loops seamlessly, and you are always prompted for the save location.
- Loop Axis: for multi-dimensional images (e.g. a time series), pick an extra (non-displayed) axis to page through frame-by-frame while the camera keeps spinning — the number of captured frames then matches that axis's length instead of a fixed 360° rotation, and the FPS field controls playback speed of the resulting file.
- A progress bar and Cancel button are shown while frames are captured; the (often slower) file encoding step runs in a background thread so napari stays fully interactive.
Compress tab
- Compress Animation... shrinks an existing GIF/MP4/WebP/MOV/AVI file. Choose a compression scheme — WebP or MP4 use lossy, per-frame (JPEG-like) image compression instead of GIF's 256-color palette, which avoids the choppy banding/dithering artifacts a plain palette-based GIF produces. Compression automatically tries progressively lower scale/quality tiers until the output is under 25 MB (handy for e-mail attachments), while never dropping below 24 fps.
Usage
- Open napari with a 3D (or higher-dimensional) volume layer and switch to
3D display (
ndisplay=3). - Open
Plugins > napari-volume-spin: Volume Spin Controls. - On the Spin Controls tab, pick a rotation axis and speed, then click Play Spin to start the continuous animation.
- Switch to the Export tab, choose GIF or MP4, an FPS, and optionally a Loop Axis (for multi-dimensional images), then click Export Looping Animation.... Use Cancel to abort mid-capture.
- If the resulting file is too large (e.g. for e-mail), switch to the Compress tab, pick a compression scheme, and click Compress Animation... to save a smaller copy.
Installation
You can install napari-volume-spin via pip:
pip install napari-volume-spin
If napari is not already installed, you can install napari-volume-spin with napari and Qt via:
pip install "napari-volume-spin[all]"
To install latest development version:
pip install git+https://github.com/Macl-I/napari-volume-spin.git
Contributing
Contributions are very welcome. Tests can be run with tox, please ensure the coverage at least stays the same before you submit a pull request.
License
Distributed under the terms of the BSD-3 license, "napari-volume-spin" is free and open source software
Issues
If you encounter any problems, please file an issue along with a detailed description.
Release files for napari-volume-spin 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| napari_volume_spin-0.1.0.tar.gz | 11.9 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| napari_volume_spin-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.0 MB
Release files / napari_volume_spin-0.1.0.tar.gz
| Download URL | napari_volume_spin-0.1.0.tar.gz |
|---|---|
| Size | 11.9 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a281f1d0210c1693b80cd3955e7b1cd868283650244e855e51190262cc3ad232
|
|
BLAKE2b-256 checksum How to use checksums |
f766f350f7be481623ec0b60d77924c89b14ab2ff2111c51d17ae5d3ee58e37f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 24, 2026.
Transparency logRelease files / napari_volume_spin-0.1.0-py3-none-any.whl
| Download URL | napari_volume_spin-0.1.0-py3-none-any.whl |
|---|---|
| Size | 11.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1dd0872675c4ad082a89e3ca3280137239adfdb39dc57bae915d002fdb47e541
|
|
BLAKE2b-256 checksum How to use checksums |
f3f139f164bdb6e92c7f563e6e037d9e105e78dd5c62d98e123dfdd2535c3a36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 24, 2026.
Transparency log