Add shadow compute shader (voxelShadowCS.hlsl) that traces rays toward the sun using DXR inline ray queries (RayQuery<>, SM 6.5). Shadows modulate voxelRT_ in-place via RWTexture2D (no extra render target). Key fixes to Phase 6.1 BLAS/TLAS infrastructure: - Sequential index buffer required: Wicked treats IndexCount=0 with non-null IndexBuffer as "0 indexed triangles" → empty BLAS - Memory barriers between BLAS→TLAS→RT: without GPUBarrier::Memory() the TLAS build races with BLAS builds, causing zero ray hits - inverseViewProjection added to VoxelCB for depth reconstruction F5 toggles shadows OFF→ON→DEBUG (red=hit, green=miss, blue=backface). |
||
|---|---|---|
| .. | ||
| voxelBLASExtractCS.hlsl | ||
| voxelCommon.hlsli | ||
| voxelCullCS.hlsl | ||
| voxelMeshCS.hlsl | ||
| voxelPS.hlsl | ||
| voxelShadowCS.hlsl | ||
| voxelSmoothCentroidCS.hlsl | ||
| voxelSmoothCS.hlsl | ||
| voxelSmoothPS.hlsl | ||
| voxelSmoothVS.hlsl | ||
| voxelTopingPS.hlsl | ||
| voxelTopingVS.hlsl | ||
| voxelVS.hlsl | ||