Move files
This commit is contained in:
parent
77e2013961
commit
339862a6ac
14 changed files with 23 additions and 48 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import { smartCompile } from '../smart-compile';
|
||||
import shader from './full-screen-quad.wgsl';
|
||||
import { smartCompile } from './smart-compile';
|
||||
|
||||
export const setUpFullScreenQuad = (
|
||||
device: GPUDevice
|
||||
|
|
@ -26,7 +26,22 @@ export const setUpFullScreenQuad = (
|
|||
return {
|
||||
buffer,
|
||||
vertex: {
|
||||
module: smartCompile(device, shader),
|
||||
module: smartCompile(
|
||||
device,
|
||||
/* wgsl */ `
|
||||
struct VertexOutput {
|
||||
@builtin(position) position: vec4<f32>,
|
||||
@location(0) uv: vec2<f32>,
|
||||
}
|
||||
|
||||
@vertex
|
||||
fn vertex(
|
||||
@location(0) position: vec2<f32>,
|
||||
@location(1) uv: vec2<f32>
|
||||
) -> VertexOutput {
|
||||
return VertexOutput(vec4(position, 0.0, 1.0), uv);
|
||||
}`
|
||||
),
|
||||
entryPoint: 'vertex',
|
||||
buffers: [
|
||||
{
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
struct VertexOutput {
|
||||
@builtin(position) position: vec4<f32>,
|
||||
@location(0) uv: vec2<f32>,
|
||||
}
|
||||
|
||||
@vertex
|
||||
fn vertex(
|
||||
@location(0) position: vec2<f32>,
|
||||
@location(1) uv: vec2<f32>
|
||||
) -> VertexOutput {
|
||||
return VertexOutput(vec4(position, 0.0, 1.0), uv);
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import { setUpFullScreenQuad } from './full-screen-quad/full-screen-quad';
|
||||
import { setUpFullScreenQuad } from './full-screen-quad';
|
||||
import { smartCompile } from './smart-compile';
|
||||
|
||||
const textureCache = new Map<string, GPUTexture>();
|
||||
|
|
|
|||
Loading…
Reference in a new issue