Add blit shader comment (#3301)

This commit is contained in:
David Huculak
2022-12-16 01:34:32 -05:00
committed by GitHub
parent 0e4c7dd6d2
commit f14bee6740

View File

@@ -3,6 +3,24 @@ struct VertexOutput {
@location(0) tex_coords: vec2<f32>,
};
// meant to be called with 3 vertex indices: 0, 1, 2
// draws one large triangle over the clip space like this:
// (the asterisks represent the clip space bounds)
//-1,1 1,1
// ---------------------------------
// | * .
// | * .
// | * .
// | * .
// | * .
// | * .
// |***************
// | . 1,-1
// | .
// | .
// | .
// | .
// |.
@vertex
fn vs_main(@builtin(vertex_index) vertex_index: u32) -> VertexOutput {
var result: VertexOutput;