Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ members = [
"examples/scenes",
"examples/simple",
"examples/with_winit",
"examples/symbols",

"sparse_strips/vello_api",
"sparse_strips/vello_bench",
Expand Down
24 changes: 24 additions & 0 deletions examples/symbols/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[package]
name = "symbols"
version = "0.1.0"
description = "An example rendering layered point, line, and polygon symbols with Vello."
edition.workspace = true
license.workspace = true
repository.workspace = true
readme = "README.md"
keywords = ["symbol", "rendering", "graphics"]
categories = ["graphics", "visualization", "rendering"]

[lints]
workspace = true

[dependencies]
vello = { workspace = true }

anyhow = { workspace = true }
clap = { workspace = true, features = ["derive"] }

pollster = { workspace = true }
env_logger = "0.11"
png = { workspace = true }
futures-intrusive = { workspace = true }
31 changes: 31 additions & 0 deletions examples/symbols/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# symbols

Headless symbol rendering example built on top of Vello Classic.

This crate demonstrates how to use a rendering pipeline to generate high-quality 2D map-like graphics, including polygons, roads, water layers, and point symbols, and export the result as a PNG image.

It is designed as an example of integrating vector-style rendering with a GPU backend using `wgpu`.

---

## Features

- Headless (offscreen) rendering using GPU
- Map-style layered rendering:
- Polygon landuse layers
- Water and river rendering
- Cased road rendering
- Grid overlay
- Point symbols with multi-layer styling
- Gradient fills, strokes, and clipping support
- Export rendered result to PNG
- Configurable antialiasing (MSAA / area)
- Optional CPU rendering mode

---

## Usage
```bash
cargo run -p symbols
cargo run -p symbols -- --width 1600 --height 900 --aa msaa16 --output output.png
```
Loading
Loading