render3d: a renderer that cannot draw says so and stops - LUDIC_HOME's leading ~ expanded (an unexpanded one left a run without shaders, logging 27 missing variants and drawing on), the SPIR-V manifest ends with E <count> and a cut or miscounted one is refused, and every such failure is a fault: r3d_open / r3d_load_step fail on it, r3d_fault() / r3d_fault_exit(code) for the game; tests/manifest_test
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
aac58ec6fa
commit
c3fc896dea
13 changed files with 227 additions and 54 deletions
|
|
@ -119,7 +119,7 @@ function r3d_open(render3d_st: mut Render3dState, w: int, h: int, title: string)
|
|||
print(`r3d: {gl_width()}x{gl_height()} on {renderer}`)
|
||||
prof_init(render3d_st)
|
||||
cam_init(render3d_st, float(gl_width()) / float(gl_height()))
|
||||
return true
|
||||
return len(render3d_st.r3d_fault) == 0
|
||||
}
|
||||
|
||||
# The load, as steps a loading screen can show between: 0 the sky and its image-based light,
|
||||
|
|
@ -128,6 +128,10 @@ function r3d_open(render3d_st: mut Render3dState, w: int, h: int, title: string)
|
|||
# grass and the sky pass. The order is r3d_init's.
|
||||
function r3d_load_count() -> int { return 4 + TERRAIN_INIT_STEPS }
|
||||
function r3d_load_step(render3d_st: mut Render3dState, i: int) -> bool {
|
||||
if not r3d_load_step_run(render3d_st, i) { return false }
|
||||
return len(render3d_st.r3d_fault) == 0 # a step that made a program with no variant fails
|
||||
}
|
||||
function r3d_load_step_run(render3d_st: mut Render3dState, i: int) -> bool {
|
||||
let t = i - 1
|
||||
if i == 0 {
|
||||
# the default sky's path is made only when no path was given, and goes once the sky is read
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue