Skip to content

Check the rendering of a few games against expected screenshots - #1114

Merged
4ian merged 3 commits into
mainfrom
claude/quirky-hopper-0qzexl
Nov 5, 2026
Merged

4ian merged 3 commits into
mainfrom
claude/quirky-hopper-0qzexl

Conversation

@4ian

@4ian 4ian commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

An early warning when the rendering of GDevelop changes.

  • Four games get a rendering test, a gameplay test named Rendering: ... taking PNG screenshots:
    • 3D island: ambient occlusion, depth of field, bloom, tone mapping, terrain, water;
    • 3D light playground: sun, point lights, spot lights, mixed lights;
    • expanded 3D house horror: models, fog, flashlight;
    • platformer: 2D.
  • scripts/check-rendering-screenshots.js runs only these tests with the latest GDevelop build. It compares each screenshot with rendering-screenshots/<example>/<label>.png; --update rewrites the expected images.
  • New rendering-screenshots CircleCI job: on main, every night, and on branches changing these games, their images or the scripts. The diff images (differences in magenta) are kept as artifacts.
  • The code running the tests of a game moves to scripts/lib/GameplayTestsRunner.js, shared by both scripts. It can now run only some tests, with --cmd-args filters.
  • The 3D island keeps only the tests useful to game creators: the player on the terrain, raised ground, slopes, and its rendering test. The tests of the terrain extension internals and editor brushes are removed.

Verified:

  • The check passes locally (master builds 5.6.286 and 5.6.287) and on CircleCI. Images made locally match CircleCI's rendering.
  • The house horror screenshot hides its "UI" layer. Its texts are drawn with the font settings of the system, which put them a pixel apart on CircleCI while the 3D was identical. The README says so for future rendering tests.
  • A modified expected image fails the check with a diff image and a JUnit failure.
  • Types, Jest tests and formatting pass.

GDevelop's own engine gets similar checks on scenes built in code, run on every PR: 4ian/GDevelop#9339.

🤖 Generated with Claude Code

https://claude.ai/code/session_01GFZna1tBkWVDbpAbTNnXpr

A few games get a rendering test (a gameplay test named "Rendering: ..."
taking PNG screenshots): the 3D island (ambient occlusion, depth of field,
bloom, tone mapping, terrain, water), the 3D light playground (sun, point
and spot lights, shadows), the expanded 3D house horror (models, fog,
flashlight, text) and the platformer (2D).

scripts/check-rendering-screenshots.js runs only these tests with the latest
build of GDevelop and compares the screenshots with the images of
rendering-screenshots/ (or writes them with --update). The new
rendering-screenshots CI job runs it on main, every night and on the branches
changing these games, their images or the scripts: an image that differs
while the game did not change is an early warning that the rendering of
GDevelop changed.

The code running the tests of a game moves to scripts/lib/GameplayTestsRunner.js,
to be shared by both scripts, and can now run only some of the tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GFZna1tBkWVDbpAbTNnXpr
The tests of the terrain extension itself (saved data, compatibility with
older versions of GDevelop, world scale, brushes of the scene editor...) are
removed: the island keeps the tests of the player on the terrain and its
rendering test. The rendering tests have no description: it is shown to the
users opening the games.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GFZna1tBkWVDbpAbTNnXpr
The texts are drawn with the font settings of the system: on CircleCI, they
were drawn a pixel apart from the expected image, while the 3D rendering was
the same. The other games show no text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GFZna1tBkWVDbpAbTNnXpr
@4ian
4ian merged commit 9c4efac into main Nov 5, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants