Repository navigation
make test-modern, test-compare and test-renderers - #37
Merged
Merged
Conversation
make test-modern runs the scripted playtest of make test on out/nolf-modern-release/. make test-compare runs both, one after the other, and puts each level's shots side by side, legacy left and modern right, in out/play/compare-test-<level>-test-modern-<level>.jpg: 640x480 a shot, 8-bit JPEG, about 2 MB, small enough to attach to a pull request. TEST_RES sets the playtests' screen mode (e.g. 1920x1080). playtest.sh compare takes the shot size (PLAYTEST_COMPARE_SIZE) and the format (PLAYTEST_COMPARE_EXT), and writes 8-bit images: the contact sheet of a 19-shot run was a 16-bit 36 MB PNG at 640x480. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
make test-renderers plays each scene of TEST_SCENES (<level>:<script>, build/scenes/) in out/nolf-modern-release/ with each of TEST_RENDERERS (d3d7.ren d3d9.ren opengl.ren) and puts the first renderer's shots beside each other's, in out/play/compare-<scene>-d3d7-<scene>-<renderer>.jpg. The same build plays a cinematic at the same speed whatever draws it, so the shots line up. A renderer the game does not load (it falls back to d3d9.ren and saves that in autoexec.cfg) fails the run. The legacy build, like the retail game, plays a cinematic faster the higher its frame rate (this one's bathroom part: about 18 s under Xvfb, 7 s on Windows with a fast GPU, where the modern build takes about 45 s), which rules it out as the reference here. The first scene, T01S02-bottle, is T01S02's opening cinematic at Cate Archer's residence, past the wine bottle and glass where d3d9.ren and opengl.ren drew the models' back faces and the chrome passes translucent. playtest.sh takes a cinestart command: until a cinematic's letterbox is on screen, the clock for timing a cinematic's shots, since a level loads in its own time. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
publicarray
marked this pull request as ready for review
October 18, 2026 09:04
nolffan
self-requested a review
October 18, 2026 11:02
nolffan
approved these changes
Oct 18, 2026
nolffan
left a comment
Owner
There was a problem hiding this comment.
LGTM. I've wanted something like this for a while.
At some point we ought to:
- build a "demo arena" that uses all features of the game engine
- write integration/play tests that use it
- commit known good renders from each renderer and use them for CI tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Playtests for the modern build, and side-by-side screenshots to check a change against a reference.
make test-modernrunsmake test's scripted playtest (tools/playtest-basic.txt,TEST_LEVELS) onout/nolf-modern-release/.make test-comparerunsmake testandmake test-modernone after the other (their containers share a name), then puts each level's shots side by side, legacy left and modern right, inout/play/compare-test-<level>-test-modern-<level>.jpg: 640x480 a shot, 8-bit JPEG, about 2 MB, small enough to attach to a pull request.TEST_RESsets the screen mode, e.g.TEST_RES=1920x1080.The first scene,
T01S02-bottle, is T01S02's opening cinematic at Cate Archer's residence, as the camera passes the wine bottle and glass on the bathroom shelf, whered3d9.renandopengl.rendrew models' back faces.Culling issue:

Fixed: in a separate PR

playtest.shgains acinestartcommand: it waits until a cinematic's letterbox is on screen, and the cinematic's shots are timed from there, since a level loads in its own time.playtest.sh comparetakes the shot size and format (PLAYTEST_COMPARE_SIZE,PLAYTEST_COMPARE_EXT) and writes 8-bit images (the 19-shot sheet was a 36 MB 16-bit PNG at 640x480).🤖 Generated with Claude Code