vello-d 0.1.0

Dlang bindings for Vello vector graphics


To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

vello-d

High-performance, GPU-accelerated 2D vector graphics for Dlang, powered by Vello (Rust).

🚀 Key Features

  • GPU Backends: Native support for Vulkan and DX12 via wgpu.
  • Multi-Window Rendering: Create multiple windows running on different GPU backends within a single process.
  • Threaded Rendering: Support for decoupled background rendering to bypass the Win32 main-loop move/resize blocking issue.
  • RAII Bindings: Ergonomic Dlang wrappers for Vello's scene and context management.

🛠️ Getting Started

1. Build the Rust Bridge

Vello is a Rust engine, so you first need to build the C-compatible bridge:

cd vello_bridge
cargo build --release

2. Run the Dlang Demos

The tests/ directory contains several configurations to demonstrate different rendering architectures:

ConfigurationCommandDescription
Simpledub run -c simpleA basic single-window Vulkan renderer.
Multi-Backenddub run -c multiVulkan + DX12 windows in one process (Shared Main Thread).
Threadeddub run -c threadedVulkan + DX12 windows (Background Threaded). Highly Recommended.

💡 Why Threaded Rendering?

On Windows, standard single-threaded main loops (like GLFW's glfwPollEvents) block when a user moves or resizes a window. By using the -c threaded configuration, each window renders in its own background thread, ensuring silky smooth animation even while the window is being dragged.

📄 Documentation

  • [Integration Challenges](file:///C:/Users/rjamd/.gemini/antigravity/brain/b9e39486-8d48-4212-a36a-956137da2bd4/vello_d_integration_challenges.md): A technical retrospective on the staging texture strategy and sRGB format compatibility.
  • [Dlang Lessons Learned](file:///Z:/code/github.com/dlang-supplemental/vello-d/source/vello/LESSONS.md): Tips for FFI safety and RAII.
  • [Rust Lessons Learned](file:///Z:/code/github.com/dlang-supplemental/vello-d/vello_bridge/LESSONS.md): Insights into wgpu feature selection and cross-adapter compatibility.

⚖️ License

MIT / Apache 2.0

Authors:
  • amdphreak
Dependencies:
none
Versions:
0.1.3 2026-Mar-26
0.1.2 2026-Mar-26
0.1.1 2026-Mar-26
0.1.0 2026-Mar-26
~main 2026-Aug-18
Show all 5 versions
Download Stats:
  • 99 downloads today

  • 99 downloads this week

  • 99 downloads this month

  • 99 downloads total

Score:
0.8
Short URL:
vello-d.dub.pm