Commit graph

30 commits

Author SHA1 Message Date
catbot
464cb66063 docs(vulkan-rt): record native descriptor-heap AS read as a driver fault
Investigated the VK_ERROR_DEVICE_LOST on the native VulkanTriangle (#7).
Verified the engine side is correct and validation-clean: the BLAS/TLAS
build finishes before render (FinishInit waits), the built instance is
well-formed (identity transform, mask=0xFF, correct BLAS ref), and
vkWriteResourceDescriptorsEXT stores the TLAS device address at the
expected heap offset (confirmed by dumping the heap bytes). Khronos
validation 1.4.350 reports zero errors.

The fault is isolated to reading the acceleration structure through
VK_EXT_descriptor_heap:
- images/buffers via the same heap render fine (trace disabled -> the
  raygen imageStore path renders a full gradient);
- both traceRayEXT and inline rayQueryEXT (no SBT) fault identically on
  the AS read;
- reproduces with the AS descriptor at heap byte 0 / shader index 0 (no
  offset/stride ambiguity) and regardless of pAddressRange size.

NVIDIA 610.43.02 is the only descriptor_heap implementation available
(llvmpipe lacks the extension), so there is no second implementation to
cross-check. Conclusion: driver-side fault in NVIDIA's brand-new
VK_EXT_descriptor_heap acceleration-structure path; should be reported to
NVIDIA. The traceRayEXT call is left active so the example stays a
faithful reproducer. Documented in both READMEs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-05-31 22:21:57 +00:00
catbot
4e42d663a6 WebGPU RT: wavefront tracer core (GENERATE/PREP/TRACE/SHADE/RESOLVE)
Replace the megakernel @compute entry with five wavefront kernels sharing
one module, connected by GPU ray/hit/payload buffers and a GPU-driven
indirect bounce loop:

  GENERATE -> (PREP -> TRACE -> SHADE) x maxDepth -> RESOLVE

- TRACE contains zero user code (pure _rtwTraverseTlas/Blas, opaque-only).
- PREP publishes dispatchWorkgroupsIndirect args from the live ray count;
  the indirect-args buffer lives in its own bind group so it is never
  bound read-write in the same dispatch that consumes it as INDIRECT.
- New emit/accumulate API: rtEmitPrimaryRay / rtEmitRay / rtAccumulate,
  plus an optional user Resolve stage (tonemap hook; identity by default).
- Per-pass WfParams via a dynamic-offset uniform ring (curIsA/bounce vary
  between passes within one submit).
- Payload-typed wfPayload binding emitted in the codegen region after the
  user's struct Payload; payload travels with each ray (2*W*H slots).
- Request maxBufferSize / maxStorageBufferBindingSize / maxComputeWorkgroups
  PerDimension so the W*H-sized work buffers fit past the 128MB baseline.

VulkanTriangle ported to the new API and renders bit-identical to the
megakernel baseline at maxDepth=1.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-05-31 16:24:41 +00:00
5553ded476 webgpu triangle 2026-05-18 18:43:30 +02:00
1f5697326c UI rewrite 3rd attempt 2026-05-02 21:08:20 +02:00
c9fd1b1585 animated example 2026-05-02 00:03:24 +02:00
216972e73a new UI system 2026-05-01 23:35:37 +02:00
d840a81448 bugfixes 2026-04-30 23:15:43 +02:00
177f873639 vulkan UI 2026-04-09 00:15:09 +02:00
f8e142fb06 descriptor heap rewrite 2026-04-05 22:53:59 +02:00
d661c88ee2 cleaned up renderer 2026-03-09 20:10:19 +01:00
72bf6c83e1 windows build fix 2026-03-02 23:53:13 +01:00
b5e69c90fa Win32 vulkan window 2026-02-24 02:32:37 +01:00
d1b8e45fb6 new descriptor layout 2 2026-02-03 21:03:11 +01:00
74832c6824 templated pipeline 2026-01-31 21:08:42 +01:00
1d0b7a615b descriptor fixed 2026-01-29 23:43:54 +01:00
5e3a7738ed fixed descriptors 2026-01-29 23:31:56 +01:00
83bb8ebd61 instance transform 2026-01-29 20:35:55 +01:00
642cef78b1 buffered TLAS 2026-01-29 19:46:53 +01:00
550590d6ee rgba8 2026-01-29 19:26:02 +01:00
96b5d1a299 vulkan triangle 2026-01-29 19:18:47 +01:00
8b2fd773b1 working RT 2026-01-29 02:05:18 +01:00
e4e7c66808 RT descriptors 2026-01-29 01:31:17 +01:00
7b24f52764 RT pipeline 2026-01-29 00:45:02 +01:00
962cc4b8cb descriptor 2026-01-28 23:45:33 +01:00
9f62233a07 shader 2026-01-28 23:37:12 +01:00
e08d5f104a TLAS 2026-01-28 19:16:28 +01:00
2e11ac6484 improved vulkanbuffer 2026-01-28 18:51:11 +01:00
b49abf3d1a BLAS 2026-01-28 01:06:48 +01:00
e7d0bc8f8e new structure complete 2025-11-16 18:52:52 +01:00
c82c8c0887 commit 2025-11-16 15:32:03 +01:00