mirror of
https://github.com/gfx-rs/wgpu.git
synced 2025-12-08 21:26:17 +00:00
This will make it easier for contributors to understand the file layout,
at the cost of said layout containing several more nested directories.
I will personally appreciate not having to remember to look for
`root.rs` instead of `main.rs`.
I also renamed the test targets so that they do not *all* share the
superfluous suffix “-test” (test targets live in a different namespace
than other target types and packages, so the name can presume that it
is always known that they are tests).
The Naga snapshot data sets `naga/tests/{in,out}` have been left in
their original positions.
84 lines
2.3 KiB
Plaintext
84 lines
2.3 KiB
Plaintext
(
|
|
features: "",
|
|
expectations: [
|
|
(
|
|
name: "Render Target",
|
|
buffer: (index: 0, epoch: 1),
|
|
offset: 0,
|
|
data: File("zero-16k.bin", 16384),
|
|
),
|
|
// MISSING: Partial view.
|
|
],
|
|
actions: [
|
|
CreateTexture(Id(0, 1), (
|
|
label: Some("Render Target Texture"),
|
|
size: (
|
|
width: 64,
|
|
height: 64,
|
|
),
|
|
mip_level_count: 1,
|
|
sample_count: 1,
|
|
dimension: r#2d,
|
|
format: "rgba8unorm",
|
|
usage: "RENDER_ATTACHMENT | COPY_SRC",
|
|
view_formats: [],
|
|
)),
|
|
CreateTextureView(
|
|
id: Id(0, 1),
|
|
parent_id: Id(0, 1),
|
|
desc: (),
|
|
),
|
|
CreateBuffer(
|
|
Id(0, 1),
|
|
(
|
|
label: Some("Render Target Buffer"),
|
|
size: 16384,
|
|
usage: "MAP_READ | COPY_DST",
|
|
mapped_at_creation: false,
|
|
),
|
|
),
|
|
|
|
Submit(1, [
|
|
RunRenderPass(
|
|
base: (
|
|
commands: [],
|
|
dynamic_offsets: [],
|
|
string_data: [],
|
|
push_constant_data: [],
|
|
),
|
|
target_colors: [
|
|
Some((
|
|
view: Id(0, 1),
|
|
resolve_target: None,
|
|
load_op: load,
|
|
store_op: store,
|
|
clear_value: (
|
|
r: 1, g: 1, b: 1, a: 1,
|
|
),
|
|
)),
|
|
],
|
|
target_depth_stencil: None,
|
|
),
|
|
CopyTextureToBuffer(
|
|
src: (
|
|
texture: Id(0, 1),
|
|
mip_level: 0,
|
|
array_layer: 0,
|
|
),
|
|
dst: (
|
|
buffer: Id(0, 1),
|
|
layout: (
|
|
offset: 0,
|
|
bytes_per_row: Some(256),
|
|
rows_per_image: Some(64),
|
|
),
|
|
),
|
|
size: (
|
|
width: 64,
|
|
height: 64,
|
|
),
|
|
),
|
|
]),
|
|
],
|
|
)
|