vello-d ~main

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:

<a id="readme-top"></a> <div align="center"> <a href="https://github.com/dlang-supplemental/vello-d/graphs/contributors"><img src="https://img.shields.io/github/contributors/dlang-supplemental/vello-d.svg?style=for-the-badge" alt="Contributors"></a> <a href="https://github.com/dlang-supplemental/vello-d/network/members"><img src="https://img.shields.io/github/forks/dlang-supplemental/vello-d.svg?style=for-the-badge" alt="Forks"></a> <a href="https://github.com/dlang-supplemental/vello-d/stargazers"><img src="https://img.shields.io/github/stars/dlang-supplemental/vello-d.svg?style=for-the-badge" alt="Stargazers"></a> <a href="https://github.com/dlang-supplemental/vello-d/issues"><img src="https://img.shields.io/github/issues/dlang-supplemental/vello-d.svg?style=for-the-badge" alt="Issues"></a>

<h1 align="center">vello-d</h1>

<p align="center">

High-performance, GPU-accelerated 2D vector graphics for Dlang, powered by Vello (Rust).
<br />
<br />
<a href="https://github.com/dlang-supplemental/vello-d/issues">Report Bug</a>
&middot;
<a href="https://github.com/dlang-supplemental/vello-d/issues">Request Feature</a>

</p> </div>

<details> <summary>Table of Contents</summary> <ol>

<li><a href="#about-the-project">About The Project</a></li>
<li><a href="#getting-started">Getting Started</a></li>
<li><a href="#usage">Usage</a></li>
<li><a href="#contact">Contact</a></li>

</ol> </details>

About The Project

Install: dub add vello-d (after building the Rust bridge below).

Key Features

  • GPU Backends: Native support for Vulkan and DX12 via wgpu.
  • Surfaces: Windows HWND, X11 (Display* + window id), Wayland (wl_display* + wl_surface*).
  • Scene API: fills, strokes, rounded rects, circles, Bézier paths, clip layers, linear/radial gradients, RGBA8 images, TrueType glyph runs.
  • 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.

Changelog

See CHANGELOG.adoc.

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

Usage

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

  • [Dlang Lessons Learned](source/vello/LESSONS.md): Tips for FFI safety and RAII.
  • [Rust Lessons Learned](vello_bridge/LESSONS.md): Insights into wgpu feature selection and cross-adapter compatibility.

License

MIT / Apache 2.0

Contact

DLang Supplemental — [email protected]

Project Link: https://github.com/dlang-supplemental/vello-d

Site: https://dlang-supplemental.github.io

<p align="right">(<a href="#readme-top">back to top</a>)</p>

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