mirror of
https://github.com/italicsjenga/vello.git
synced 2025-01-10 20:51:29 +11:00
af0a1af8e1
The backdrop propagation is slow but it does work.
23 lines
481 B
Rust
23 lines
481 B
Rust
use piet_gpu_derive::piet_gpu;
|
|
|
|
piet_gpu! {
|
|
#[gpu_write]
|
|
mod tile {
|
|
struct Path {
|
|
bbox: [u16; 4],
|
|
tiles: Ref<Tile>,
|
|
}
|
|
struct Tile {
|
|
tile: Ref<TileSeg>,
|
|
backdrop: i32,
|
|
}
|
|
// Segments within a tile are represented as a linked list.
|
|
struct TileSeg {
|
|
start: [f32; 2],
|
|
end: [f32; 2],
|
|
y_edge: f32,
|
|
next: Ref<TileSeg>,
|
|
}
|
|
}
|
|
}
|