diff options
Diffstat (limited to 'src/effects/scratch_effect.h')
| -rw-r--r-- | src/effects/scratch_effect.h | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/src/effects/scratch_effect.h b/src/effects/scratch_effect.h index fb36a96..6c0e0cb 100644 --- a/src/effects/scratch_effect.h +++ b/src/effects/scratch_effect.h @@ -1,20 +1,13 @@ // Scratch effect - film scratch overlay post-process -// Reads input buffer, additively blends scratch_lines() on top. #pragma once -#include "gpu/effect.h" -#include "gpu/wgpu_resource.h" +#include "effects/shaders.h" +#include "gpu/wgsl_effect.h" -class Scratch : public Effect { - public: +struct Scratch : public WgslEffect { Scratch(const GpuContext& ctx, const std::vector<std::string>& inputs, const std::vector<std::string>& outputs, float start_time, - float end_time); - - void render(WGPUCommandEncoder encoder, const UniformsSequenceParams& params, - NodeRegistry& nodes) override; - - private: - RenderPipeline pipeline_; - BindGroup bind_group_; + float end_time) + : WgslEffect(ctx, inputs, outputs, start_time, end_time, + scratch_shader_wgsl) {} }; |
