Skip to main content

NanoVDB Editor Python Module

Project description

NanoVDB Editor

Prerequisities:

  • numpy

Running in Docker

To run the editor in the docker container, the Dockerfile needs to contain:

EXPOSE 8080

ENV NVIDIA_DRIVER_CAPABILITIES compute,graphics,utility

RUN apt-get update \
    && apt-get install -y \
    libxext6 \
    libegl1

Then run with the NVIDIA runtime selected (https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html):

docker run --runtime=nvidia --net=host --gpus=all ...

Hello World

import nanovdb_editor as nve

editor, compute, compiler = nve.create_default(device_id=args.device)

config = nve.EditorConfig()

# Default values, set as needed
config.ip_address = b"127.0.0.1"
config.port = 8080
config.headless = 0
config.streaming = 0

editor.show(config)
# editor.wait_for_interrupt()   # uncomment when streaming is enabled

Shader Parameters

Shaders can have defined struct with shader parameters which are intended to be shown in the editor's UI:

struct shader_params_t
{
    float4 color;
    bool use_color;
    bool3 _pad1;
    int _pad2;
};
ConstantBuffer<shader_params_t> shader_params;

Shader parameters can have defined default values in the json file:

{
    "ShaderParams": {
        "color": {
            "value": [1.0, 0.0, 1.0, 1.0],
            "min": 0.0,
            "max": 1.0,
            "step": 0.01
        }
    }
}

Supported types: bool, int, uint, int64, uint64, float and its vectors and 4x4 matrix. Variables with _pad in the name are not shown in the UI. Those parameters can be interactively changed with generated UI in the editor's Params tab.

To display a group of shader parameters from different shaders define a json file with various shader paths:

{
    "ShaderParams": [
        "editor/editor.slang",
        "test/test.slang"
    ]
}

Acknowledgements

This project makes use of the following libraries:

  • zlib – Compression library
  • c-blosc – High-performance compressor optimized for binary data
  • Vulkan-Headers – Vulkan API headers
  • Vulkan-Loader – Vulkan ICD loader
  • GLFW – Windowing, context, and input (optional)
  • Dear ImGui – Immediate-mode GUI
  • ImGuiFileDialog – File dialog for Dear ImGui
  • ImGuiColorTextEdit – Syntax-highlighted text/code editor widget
  • Slang – Shading language and compiler
  • filewatch – Cross-platform file watching
  • JSON for Modern C++ – JSON serialization for C++
  • cnpy – Read/write NumPy .npy/.npz files from C++
  • zstr – Transparent zlib iostream wrappers
  • llhttp – High-performance HTTP parser
  • Asio – Asynchronous networking and concurrency primitives
  • RESTinio – Lightweight HTTP server framework
  • fmt – Modern formatting library
  • argparse – Header-only argument parser for C++17
  • expected-lite – std::expected-like type for C++11/14/17
  • libE57Format – E57 point cloud IO (optional)
  • OpenH264 – H.264 encoder (optional)
  • GoogleTest – C++ testing framework

Many thanks to the authors and contributors of these projects.

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

nanovdb_editor_dev-0.1.1.tar.gz (24.5 kB view details)

Uploaded Source

Built Distributions

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

nanovdb_editor_dev-0.1.1-py3-none-win_arm64.whl (14.9 MB view details)

Uploaded Python 3Windows ARM64

nanovdb_editor_dev-0.1.1-py3-none-win_amd64.whl (53.3 MB view details)

Uploaded Python 3Windows x86-64

nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_35_x86_64.whl (75.0 MB view details)

Uploaded Python 3manylinux: glibc 2.35+ x86-64

nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_34_aarch64.whl (23.4 MB view details)

Uploaded Python 3manylinux: glibc 2.34+ ARM64

File details

Details for the file nanovdb_editor_dev-0.1.1.tar.gz.

File metadata

  • Download URL: nanovdb_editor_dev-0.1.1.tar.gz
  • Upload date:
  • Size: 24.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for nanovdb_editor_dev-0.1.1.tar.gz
Algorithm Hash digest
SHA256 5b90274473487f55433fa724ac7cbeff685a8a877a13f791ca1c506f5a2b1e5b
MD5 f08b0e700ebd0e0199db9f4948f172e3
BLAKE2b-256 dbeadd4393a74f1899992c6b8d7b7b67d49229705ba6eee7811c62313485c12f

See more details on using hashes here.

File details

Details for the file nanovdb_editor_dev-0.1.1-py3-none-win_arm64.whl.

File metadata

File hashes

Hashes for nanovdb_editor_dev-0.1.1-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 01f8044d98e4160a5608fba33f277a9234fcf6b8eb7c48335119413859579260
MD5 979db0436b7cf5a3ceb11e0aaa5ca8d1
BLAKE2b-256 5463d3286706bc453523dd99052f4b6737aadefbc43425d6b8c10dcac93d6f4e

See more details on using hashes here.

File details

Details for the file nanovdb_editor_dev-0.1.1-py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for nanovdb_editor_dev-0.1.1-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 19983691b26cc61aa261049754f84031f2b6c33b9cffbae0a70068b06dee70f4
MD5 b71e620a633a81a9f29df0d6c6eebe7a
BLAKE2b-256 a0f05dca0108b9ca827b305f685b614a1c542911765d7b7c4c93a73db0fc5547

See more details on using hashes here.

File details

Details for the file nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 0ac990d8e3943979bd2217c18880ff58750e08447ac6cf021f83ca9ab17f1a19
MD5 17f6877ca249415a9ae9b0ba21f01d5e
BLAKE2b-256 61542752cb2fa73110c8bb43ac7d04a36bb0f9efd0b3c3ee9b4b8d663d5accf3

See more details on using hashes here.

File details

Details for the file nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for nanovdb_editor_dev-0.1.1-py3-none-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 e70c06ca9e1ab2b6dd3981d0febc71d1d4b860432e070c6c3c870efa9eaf7068
MD5 b5ebbd69ecaf4cdef7847b62983727e1
BLAKE2b-256 8f880419849b673bfd32194bc3210e044a75778d4ca6ebf16e46711659cf5dc6

See more details on using hashes here.

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