summaryrefslogtreecommitdiff
path: root/src/effects/passthrough_effect.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/effects/passthrough_effect.cc')
-rw-r--r--src/effects/passthrough_effect.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/effects/passthrough_effect.cc b/src/effects/passthrough_effect.cc
index ba98657..c4106b1 100644
--- a/src/effects/passthrough_effect.cc
+++ b/src/effects/passthrough_effect.cc
@@ -9,6 +9,11 @@ PassthroughEffect::PassthroughEffect(const GpuContext& ctx,
const std::vector<std::string>& outputs)
: Effect(ctx, inputs, outputs), pipeline_(nullptr), bind_group_(nullptr),
sampler_(nullptr) {
+ // Headless mode: skip GPU resource creation
+ if (ctx_.device == nullptr) {
+ return;
+ }
+
// Init uniform buffer
uniforms_buffer_.init(ctx_.device);
// Create pipeline (simple version without effect params)