summaryrefslogtreecommitdiff
path: root/src/effects/scene1_effect.h
diff options
context:
space:
mode:
authorskal <pascal.massimino@gmail.com>2026-02-20 12:08:34 +0100
committerskal <pascal.massimino@gmail.com>2026-02-20 12:08:34 +0100
commit850388bcaabf057beed8f126002b7b663183b2d8 (patch)
treef55fad742d99dc91d2bf32ad54a27f95e8a183f3 /src/effects/scene1_effect.h
parent1030807a58c8f4315d209c3756a9f98d8dc6bd91 (diff)
feat(sequence): port Scene1Effect + fix seq_compiler absolute time bug
- Add Scene1 effect: raymarching cube+sphere+ground (reflections, shadows) - Fix scene1.wgsl: binding 0→2, CommonUniforms→UniformsSequenceParams - Replace Heptagon+Placeholder stub in heptagon_scene with Scene1 - Fix seq_compiler.py: emit seq.start_time+effect.start/end (absolute times) so dispatch_render active check works correctly for all sequences Bug: effects in sequences starting after t=0 were never active because local times (e.g. 0-8) never satisfied params.time<end for absolute time 20+. 34/34 tests passing. handoff(Gemini): seq_compiler now emits absolute effect times. All existing sequences affected — verify visual output across the full timeline. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'src/effects/scene1_effect.h')
-rw-r--r--src/effects/scene1_effect.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/effects/scene1_effect.h b/src/effects/scene1_effect.h
new file mode 100644
index 0000000..781cbae
--- /dev/null
+++ b/src/effects/scene1_effect.h
@@ -0,0 +1,21 @@
+// Scene1 effect - raymarching cube & sphere scene
+
+#pragma once
+
+#include "gpu/effect.h"
+#include "gpu/uniform_helper.h"
+#include "gpu/wgpu_resource.h"
+
+class Scene1 : public Effect {
+ public:
+ Scene1(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_;
+};