Skip to main content

Volumesh

Utility for creating volumetric mesh container files in glTF format.

Hypergrid

Hypergrid example (hypergrid.glb) (Source: Justin Jensen)

Installation

pip install volumesh

Draco Compression

To install the Google Draco compression, the DracoPy library is required. As it is still under development, we only include it when the extra draco is specified.

pip install "volumesh[draco]"

Usage

To convert a sequence of OBJ files into a volumesh container use the following command:

volumesh ./data test.glb

First specify the folder where the OBJs are located (data) and then the output file (test.glb). Use the --compressed flag if you have draco extras installed and want to compress the container. The following information is stored in the mesh, if available::

  • vertices
  • triangle indices
  • normals
  • vertex-uvs
  • textures (png / jpeg)

Limitations

When Draco compression is enabled, only vertex and triangle information is stored in the mesh. This is due to the fact that DracoPy only supports these two primitives. At the moment we recommend not to use the internal compression, but to convert the sequence to a glb file and convert it later with the gltf-pipeline. This gives a much better compression and still contains all the information:

gltf-pipeline -i .\sequence.glb -o .\sequence-draco.glb -d

Animation

To use the GLTF animation system to render the meshes in a sequence, it is possible to specify the frame rate (default 24) and set the animation flag. Volumesh will add an animation track that will fade the objects in and out using the GLTF animation tools.

volumesh ./human test.glb --animate --fps 24

Help

usage: volumesh [-h] [--compressed] [--jpeg-textures]
                [--jpeg-quality JPEG_QUALITY] [--animate] [--fps FPS]
                [-tex TEXTURE_SIZE] [--load-safe]
                input output

A utility to create volumesh files.

positional arguments:
  input                 Path to the mesh (*.obj) files (directory).
  output                GLTF output file (.glb).

options:
  -h, --help            show this help message and exit
  --compressed          Compress the mesh data with Draco compression.
  --jpeg-textures       Use JPEG compression for textures instead of PNG.
  --jpeg-quality JPEG_QUALITY
                        JPEG quality parameter.
  --animate             Animate mesh frames with GLTF animation system.
  --fps FPS             Animation frames per second (fps).
  -tex TEXTURE_SIZE, --texture-size TEXTURE_SIZE
                        Limit texture size to the specified width.
  --load-safe           Load meshes slow but save.

Credits

Developed at the Immersive Arts Space, Zurich University of the Arts (ZHdK).

Copyright © Zurich University of the Arts (ZHdK).

Metadata

Release files for volumesh 1.5.0

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 volumesh 1.5.0
File Interpreter ABI Platform
volumesh-1.5.0-py3-none-any.whl Python 3 none any Details

Release files / volumesh-1.5.0-py3-none-any.whl

Download URL volumesh-1.5.0-py3-none-any.whl
Size 11.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
288aff4b79e9c78d46164c7b7b2d521f922d3cb77c12cde8edd22a09c04512b3
BLAKE2b-256 checksum
How to use checksums
524cfd7d7ab7d047ea92c254f2e2721f53e0dc05e9a42bbd325e3ce30198b2fa
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release history Release notifications | RSS feed

This release

1.5.0 This release

1 release file

1.4.0

1 release file

1.3.0

1 release file

1.2.5.1

1 release file

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