blob: 6be375d21f0f931bfadc5030bfd3a1fe6ec81382 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// This file is part of the 64k demo project.
// It declares the FlashEffect - brief white flash on beat hits.
#pragma once
#include "gpu/effect.h"
#include "gpu/gpu.h"
class FlashEffect : public PostProcessEffect {
public:
FlashEffect(const GpuContext& ctx);
void render(WGPURenderPassEncoder pass, float time, float beat,
float intensity, float aspect_ratio) override;
void update_bind_group(WGPUTextureView input_view) override;
private:
float flash_intensity_ = 0.0f;
};
|