diff options
| author | skal <pascal.massimino@gmail.com> | 2026-02-01 16:18:19 +0100 |
|---|---|---|
| committer | skal <pascal.massimino@gmail.com> | 2026-02-01 16:18:19 +0100 |
| commit | 1522b95c838fc3e567066fd96dede3dca25cbc95 (patch) | |
| tree | 24dd8d2bc586f8b9f8f3518b4fe68907e8eeb1d4 /src/gpu/gpu.cc | |
| parent | 1481b0a6313b725eec3e3ebeea085e98703df00f (diff) | |
feat(gpu): Integrate bumpy 3D renderer into main demo
- Added depth buffer support to MainSequence.
- Implemented Hybrid3DEffect for the main timeline.
- Fixed effect initialization order in MainSequence.
- Ensured depth-stencil compatibility for all scene effects.
- Updated demo sequence with 3D elements and post-processing.
Diffstat (limited to 'src/gpu/gpu.cc')
| -rw-r--r-- | src/gpu/gpu.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gpu/gpu.cc b/src/gpu/gpu.cc index 3cdf9aa..17d32ee 100644 --- a/src/gpu/gpu.cc +++ b/src/gpu/gpu.cc @@ -147,6 +147,13 @@ RenderPass gpu_create_render_pass(WGPUDevice device, WGPUTextureFormat format, pipeline_desc.multisample.mask = 0xFFFFFFFF; pipeline_desc.fragment = &fragment_state; + // Depth Stencil State (Required for compatibility with MainSequence pass) + WGPUDepthStencilState depth_stencil = {}; + depth_stencil.format = WGPUTextureFormat_Depth24Plus; + depth_stencil.depthWriteEnabled = WGPUOptionalBool_False; + depth_stencil.depthCompare = WGPUCompareFunction_Always; + pipeline_desc.depthStencil = &depth_stencil; + pass.pipeline = wgpuDeviceCreateRenderPipeline(device, &pipeline_desc); return pass; |
