vello/piet-gpu-types/src/bins.rs
Raph Levien 343e4c3075 Binning stage
Adds a binning stage. This is a first draft, and a number of loose ends
exist.
2020-05-12 17:34:15 -07:00

20 lines
413 B
Rust

use piet_gpu_derive::piet_gpu;
// The output of the binning stage, organized as a linked list of chunks.
piet_gpu! {
#[gpu_write]
mod bins {
struct BinInstance {
element_ix: u32,
}
struct BinChunk {
// First chunk can have n = 0, subsequent ones not.
n: u32,
next: Ref<BinChunk>,
// Instances follow
}
}
}