blob: 4daf13d398a816496d9e1f8163ab14779bca26b0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
// GBufDeferredEffect — simple deferred render from packed G-buffer.
// Inputs: feat_tex0, feat_tex1 (rgba32uint). Output: albedo * shadow (rgba8unorm).
#pragma once
#include "gpu/effect.h"
#include "gpu/uniform_helper.h"
#include "gpu/wgpu_resource.h"
class GBufDeferredEffect : public Effect {
public:
GBufDeferredEffect(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_;
};
|