From 28af3138598e5c5f7e4d7c70218c26f4d2f46208 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sat, 18 Nov 2023 02:39:47 +0100 Subject: works very well --- flowy/src/motion/dec.wgsl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'flowy/src/motion/dec.wgsl') diff --git a/flowy/src/motion/dec.wgsl b/flowy/src/motion/dec.wgsl index 982a1be..2fa3f3b 100644 --- a/flowy/src/motion/dec.wgsl +++ b/flowy/src/motion/dec.wgsl @@ -7,6 +7,7 @@ struct Params { struct BlockOffset { score: f32, offset: vec2, + tint: vec3, } @group(0) @binding(0) var params: Params; @@ -22,7 +23,7 @@ struct BlockOffset { for (var x = 0; x < params.block_size.x; x++) { for (var y = 0; y < params.block_size.y; y++) { let base = uv+vec2(x,y); - let col = textureLoad(prev, base+bl.offset, 0); + let col = textureLoad(prev, base+bl.offset, 0)+vec4(bl.tint,1.); textureStore(next, base, col); }} } -- cgit v1.2.3-70-g09d2