gfx, luminance, vulkano, wgpu, rafx, sierra …
Yet another graphics library?
Case: Rusty Vangers
Lots workloads where CPU costs are small:
Constraints…
No per-object state. No image layout transitions.
Global barriers between passes.
if let mut pass_encoder = encoder.compute() {
let mut pipeline_encoder = pass_encoder.with(pipeline);
pipeline_encoder.dispatch(..);
}
No layouts. No descriptor sets.
No uniform buffers, just plain data.
#[derive(bytemuck::Pod)]
struct MyUniformStruct {
data: u32
}
#[derive(blade::ShaderData)]
struct Foo {
texture: blade::TextureView,
uniform: MyUniformStruct,
}
let foo_layout = <Foo as blade::ShaderData>::layout();
context.create_pipeline(blade::ComputePipelineDescriptor {
data_layouts: &[&foo_layout],
});
pass.bind(0, &Foo {
texture: my_texture_view,
uniform: MyUniformStruct { // plain data
data: 1,
},
});
Makes prototyping a breeze!
Was BG/BGL/PL a design mistake in WebGPU?
Disclaimer: Blade is much incomplete!
Can do around 20K draw calls per frame on a low-end laptop.
Who needs vertex buffers, anyway?
One context - one window.
All libraries: we got you!
Blade: bring your own maintainer
See What it feels like to be an open-source maintainer
Resource objects: light and copyable.
pub struct Buffer {
raw: vk::Buffer,
memory_handle: usize,
mapped_data: *mut u8,
}
Context: Has everything, internally synchronized.
Validated(*) WGSL modules.
Without resource binding decorations!
var sprite_texture: texture_2d<f32>;
var sprite_sampler: sampler;
or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Syncing