render3d: heightgen's plain and SMOOTH variants compiled (61 programs) - a smoothed or noise-only terrain had no height field on Vulkan; run-time defines as pure functions (program_defs.ludic) and manifest_test holds every program the source can ask for, literal or computed, to the manifest

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Orkun ÇAKILKAYA 2026-09-29 22:30:35 +03:00
parent a8ccd34559
commit 9f07fc8a62
12 changed files with 254 additions and 11 deletions

View file

@ -96,9 +96,8 @@ function grass_init(render3d_st: mut Render3dState) -> void {
@alloc_ok("start-up: the device, its tables, the programs, the passes and the world's first textures are made once, before play")
function grass_init__t(render3d_st: mut Render3dState) -> void {
render3d_st.grass_merge = gpu_has_mdi(render3d_st) and not r3d_env_has(render3d_st, "R3D_GRASS_TILES")
var defs = "#define FOLIAGE\n#define BLADE\n#define GBLADE\n"
let defs = grass_defs(render3d_st.grass_merge)
if render3d_st.grass_merge {
defs = defs + "#define TILES\n"
render3d_st.grass_rec = words(GRASS_RECS * 5); render3d_st.grass_tv = floats(GRASS_RECS * 4); render3d_st.grass_chunk_tv = floats(GRASS_CHUNK * 4)
render3d_st.grass_band_start = words(4); render3d_st.grass_band_cells = words(4)
render3d_st.grass_band_mesh = new []Mesh