ludic/packages/ludic.render3d
Orkuncakilkaya cdfffa62bb render3d: grass in chunks of 256 tiles a draw, flower casters only into the cascades they reach
Grass (Vulkan with multi-draw indirect): every visible tile is a record in one buffer, uploaded once a
frame, and each band draws its records 256 at a time. A record's firstInstance is its place in the
chunk times 65536; grass.vert's TILES variant reads that place's corner and indices per cell from
u_tiles. R3D_GRASS_TILES=1 keeps a draw per tile. OpenGL is unchanged.

Casters: a LOD level with no impostor is drawn into a shadow cascade only when its distance band,
widened by six times its height, the camera's height over the ground and the frustum's corner reach,
can touch that cascade's receivers. The flowers' mesh levels (6 - 30 m) leave the three outer
cascades. R3D_CAST_ALL=1 draws every level everywhere. OpenGL frames byte-identical at all five
viewpoints; alpha-tested shadow draws at a 460 -> 244.

gpu_has_mdi() guards both this and the GPU-culled trees' multi-record draws.

Camp: Mac Vulkan 2645 -> 2191 (grass) -> 2034 draws; PC 2657 -> 2046, self-tests 59/59, validation 0.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-15 16:58:53 +03:00
..
shaders render3d: grass in chunks of 256 tiles a draw, flower casters only into the cascades they reach 2026-09-15 16:58:53 +03:00
actor.ludic perf(render3d): the sky light baked once at start, the terrain load in four steps, actor cull bounds by height 2026-09-15 15:03:06 +03:00
assets.manifest feat(gl): OpenGL 4.1 and the ludic.render3d renderer 2026-09-10 03:31:12 +03:00
camera.ludic feat(gl): OpenGL 4.1 and the ludic.render3d renderer 2026-09-10 03:31:12 +03:00
collide.ludic feat(render3d): replace the world at run time, water bodies, terrain_sea 2026-09-13 00:03:40 +03:00
daylight.ludic feat(render3d): load steps for a loading screen, four quality switches, and the ring's uniform usage 2026-09-15 14:46:55 +03:00
drawstats.ludic feat(render3d): R3D_DRAWSTATS - every draw a frame makes, by pass, program and kind 2026-09-15 14:39:33 +03:00
FEATURES.md feat: per-voice audio, outlines for what is not an actor, and a coast 2026-09-11 15:25:46 +03:00
fmath.ludic feat(render3d): gpu.ludic - the seam for a second graphics API, and what the GPU can do 2026-09-15 09:52:12 +03:00
gltf.ludic render3d(vulkan): GPU-driven trees - one merged mesh per material, one draw per material; on by default 2026-09-15 16:44:00 +03:00
gpu.ludic render3d: grass in chunks of 256 tiles a draw, flower casters only into the cascades they reach 2026-09-15 16:58:53 +03:00
gpu_manifest.ludic feat(render3d): read the SPIR-V manifest the way a Vulkan backend will 2026-09-15 10:41:43 +03:00
gpu_vk.ludic perf(render3d): Vulkan device memory in blocks, and a shadow map that survives running out of it 2026-09-15 15:44:21 +03:00
gpu_vk_draw.ludic render3d(vulkan): MSAA - multisampled renderbuffers, resolved in a draw-less pass 2026-09-15 16:21:52 +03:00
gpu_vk_res.ludic render3d(vulkan): MSAA - multisampled renderbuffers, resolved in a draw-less pass 2026-09-15 16:21:52 +03:00
grass.ludic render3d: grass in chunks of 256 tiles a draw, flower casters only into the cascades they reach 2026-09-15 16:58:53 +03:00
mesh.ludic perf(render3d): Vulkan draws find pipelines by integer and reuse descriptor sets 2026-09-15 13:22:51 +03:00
overlay.ludic refactor(render3d): programs, GPU timers and the context behind gpu.ludic 2026-09-15 11:33:01 +03:00
package.ludic feat(gl): OpenGL 4.1 and the ludic.render3d renderer 2026-09-10 03:31:12 +03:00
post.ludic render3d(vulkan): MSAA - multisampled renderbuffers, resolved in a draw-less pass 2026-09-15 16:21:52 +03:00
prof.ludic feat(render3d): R3D_DRAWSTATS - every draw a frame makes, by pass, program and kind 2026-09-15 14:39:33 +03:00
programs.ludic refactor(render3d): programs, GPU timers and the context behind gpu.ludic 2026-09-15 11:33:01 +03:00
quat.ludic feat(gl): OpenGL 4.1 and the ludic.render3d renderer 2026-09-10 03:31:12 +03:00
r3d.ludic feat(render3d): R3D_DRAWSTATS - every draw a frame makes, by pass, program and kind 2026-09-15 14:39:33 +03:00
render.ludic perf(render3d): the sky light baked once at start, the terrain load in four steps, actor cull bounds by height 2026-09-15 15:03:06 +03:00
scatter.ludic render3d: grass in chunks of 256 tiles a draw, flower casters only into the cascades they reach 2026-09-15 16:58:53 +03:00
shadow.ludic perf(render3d): Vulkan device memory in blocks, and a shadow map that survives running out of it 2026-09-15 15:44:21 +03:00
skin.ludic refactor(render3d): vertex data and draws behind gpu.ludic 2026-09-15 10:21:55 +03:00
sky.ludic perf(render3d): the sky light baked once at start, the terrain load in four steps, actor cull bounds by height 2026-09-15 15:03:06 +03:00
stream.ludic feat(render3d): load steps for a loading screen, four quality switches, and the ring's uniform usage 2026-09-15 14:46:55 +03:00
terrain.ludic perf(render3d): the sky light baked once at start, the terrain load in four steps, actor cull bounds by height 2026-09-15 15:03:06 +03:00
texture.ludic feat(render3d): texture filtering and shadow resolution a game can change while it runs 2026-09-15 14:25:55 +03:00
water.ludic refactor(render3d): programs, GPU timers and the context behind gpu.ludic 2026-09-15 11:33:01 +03:00