VTK Local Rendering using WASM
Project description
VTK Local Rendering using VTK/WASM to match server side rendering pipeline on the client side. The current code base is still at its infancy but we aim to make it the default implementation for local rendering using VTK/ParaView with trame.
License
This library is OpenSource and follow the Apache Software License
Installation
pip install trame-vtklocal
# We need a VTK that has its wasm counterpart
# This is the first version available with it
# For ParaView (not yet supported), VTK don't need to be installed
pip install "vtk==9.3.20241005.dev0" --extra-index-url https://wheels.vtk.org
Development
Build and install the Vue components
cd vue-components
npm i
npm run build
cd -
Install the library
pip install -e .
Optionally, you can develop with bleeding edge VTK by following these steps. Make sure you’ve these tools 1. git 2. CMake 3. Ninja 4. Python 5. NodeJS >= 22.0.0: https://nodejs.org/en/download/package-manager 6. Emscripten SDK: See https://emscripten.org/docs/getting_started/downloads.html#download-and-install
# Compile VTK for wasm32 architecture using emscripten. Build artifacts can be found in dev/vtk/build/wasm
./utils/build_vtk.sh -u https://gitlab.kitware.com/vtk/vtk.git -b master -t wasm32 -p RelWithDebInfo
# Compile VTK with python wrappings using system C++ compiler. Build artifacts can be found in dev/vtk/build/py
./utils/build_vtk.sh -u https://gitlab.kitware.com/vtk/vtk.git -b master -t py -p RelWithDebInfo
# Set environment variables
source ./utils/dev_environment.sh -b master -p RelWithDebInfo
Running examples
pip install trame trame-vtklocal trame-vuetify trame-vtk
# We need a VTK that has its wasm counterpart
# This is the first version available with it
# For ParaView (not yet supported), VTK don't need to be installed
pip install "vtk==9.3.20240810.dev0" --extra-index-url https://wheels.vtk.org
# regular trame app
python ./examples/vtk/cone.py
Some example are meant to test and validate WASM rendering. Some will default for remote rendering but if you want to force them to use WASM just run export USE_WASM=1 before executing them.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file trame-vtklocal-0.6.2.tar.gz
.
File metadata
- Download URL: trame-vtklocal-0.6.2.tar.gz
- Upload date:
- Size: 13.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.11.2 readme-renderer/44.0 requests/2.32.3 requests-toolbelt/1.0.0 urllib3/2.2.3 tqdm/4.66.5 importlib-metadata/8.5.0 keyring/25.4.1 rfc3986/2.0.0 colorama/0.4.6 CPython/3.10.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8ab6af4b59827fd00755f6d618dad307671818aa72e9ab4ea5c55052b99aed41 |
|
MD5 | 8e062026743bcf854057e0543b12e16c |
|
BLAKE2b-256 | e8636c061e31da8ae826d1044879c29b53d64da08800856005fddd14b31726a7 |
Provenance
File details
Details for the file trame_vtklocal-0.6.2-py3-none-any.whl
.
File metadata
- Download URL: trame_vtklocal-0.6.2-py3-none-any.whl
- Upload date:
- Size: 14.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.11.2 readme-renderer/44.0 requests/2.32.3 requests-toolbelt/1.0.0 urllib3/2.2.3 tqdm/4.66.5 importlib-metadata/8.5.0 keyring/25.4.1 rfc3986/2.0.0 colorama/0.4.6 CPython/3.10.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1c419d43550d51a9a925666ec1d9ae916af493007c9ba7c1f02b2f8c5c950582 |
|
MD5 | ec5fa474d4da967aa65c86bb5d8a63c9 |
|
BLAKE2b-256 | 3b704ef9848231549ffb98c29eb86cff8539fbc0cd6ef3430e62dd80ea9c35e5 |