Skip to main content

PyVista-like API for VTK.wasm

Project description

pyvista-wasm

JupyterLite Stlite marimo

PyVista-like API for VTK.wasm — bring intuitive 3D visualization to the browser using WebAssembly.

Try it with JupyterLite Try it with Stlite Try it with marimo
jupyterlite-preview stlite-preview marimo-preview

Table of Contents

Install

PyPI

pip install pyvista-wasm

For Pyodide/stlite:

import micropip

await micropip.install("pyvista-wasm")

Usage

import pyvista_wasm as pv

plotter = pv.Plotter()
plotter.add_mesh(pv.Sphere(), color="red")
plotter.show()

Differences from pyvista-js

This project replaces the vtk.js rendering backend used in pyvista-js with VTK.wasm (@kitware/vtk-wasm npm package).

Key differences:

  • Rendering backend: VTK.wasm (WebAssembly port of VTK C++) instead of vtk.js (pure JavaScript reimplementation)
  • API style: VTK.wasm uses vtk.vtkRenderer() factory functions on a namespace object, vs vtk.js's vtk.Rendering.Core.vtkRenderer.newInstance() hierarchy
  • Initialization: VTK.wasm requires async initialization via vtkWASM.createNamespace() to load the WASM binary
  • Feature parity: VTK.wasm provides access to the full VTK C++ API, enabling features not available in vtk.js

Contributing

Contributions are welcome! Please open an issue or pull request on GitHub.

License

Apache License 2.0 © Tetsuo Koyama

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyvista_wasm-0.8.0.tar.gz (299.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyvista_wasm-0.8.0-py3-none-any.whl (81.8 kB view details)

Uploaded Python 3

File details

Details for the file pyvista_wasm-0.8.0.tar.gz.

File metadata

  • Download URL: pyvista_wasm-0.8.0.tar.gz
  • Upload date:
  • Size: 299.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for pyvista_wasm-0.8.0.tar.gz
Algorithm Hash digest
SHA256 bf5096c87387be4661140b8f89f4544028e8e548d5b59df3c3de173c2862a6e8
MD5 529f657aa5cfa4ec0f24657d2ad78fc3
BLAKE2b-256 c4874cdfdcc560f5b3ad58abfda7e183a9c1593e4f9f3556a00ef42a0fef9df8

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvista_wasm-0.8.0.tar.gz:

Publisher: release-please.yml on tkoyama010/pyvista-wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyvista_wasm-0.8.0-py3-none-any.whl.

File metadata

  • Download URL: pyvista_wasm-0.8.0-py3-none-any.whl
  • Upload date:
  • Size: 81.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for pyvista_wasm-0.8.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8b3e1477402360b4bade0e25110d5df8134b3ca7f9cd02ec3c959de732f30031
MD5 ff18efa572482b835fce3f6b32ba913b
BLAKE2b-256 2f9fa847ab44e6edbedbf6ee0ab249fc1369c63d53533da75c09bf11265d41f8

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvista_wasm-0.8.0-py3-none-any.whl:

Publisher: release-please.yml on tkoyama010/pyvista-wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page