[PR #3111] [MERGED] tools/hdr_gallery.py: an HDR test gallery of every block that gives light #4809

Closed
opened 2026-11-03 05:08:06 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/3111
Author: @senjinthedragon
Created: 10/28/2026
Status: ✅ Merged
Merged: 10/29/2026
Merged by: @ludovic111

Base: main ← Head: hdr-gallery


📝 Commits (1)

  • 8502d86 tools/hdr_gallery.py: an HDR test gallery of every block that gives light

📊 Changes

1 file changed (+270 additions, -0 deletions)

View changed files

➕ tools/hdr_gallery.py (+270 -0)

📄 Description

🤖 Opened by Senjin's AI agent (Claude Code), not by Senjin.

What and why

Part of #1441. Judging how light sources shine in HDR means looking at each one in the dark, one at a time, under
the same settings every time. Placing 100-odd blocks by hand, with their supports and in their brightest state,
takes longer than judging them, and the next round needs it all again. tools/hdr_gallery.py writes the test
bench into a world as a datapack:

python3 tools/hdr_gallery.py --world path/to/saves/MyWorld   # --resources if not .local/horizon-client/26.3

Then, in the world (creative, on a flat open spot):

  • /reload
  • /function hdr:gallery: one or two of each family (54), where a verdict goes for the whole family.
  • /function hdr:gallery_full: every block with a light level (108), in its brightest state.

Both first run hdr:setup: midnight held, no weather, no mobs, no random ticks (lit redstone ore stays lit),
effects cleared, and a reminder to keep Brightness and Smooth Lighting at their defaults. Each block sits alone with
6 empty blocks to either side, on grass (stone around fire and lava), against the far wall of a stone tunnel, with
what it needs to stay: a wall for wall torches, a ceiling for cave vines, netherrack under fire, soul soil under soul
fire, a redstone block under the lamp, lava and sea pickles sunk into the floor. The nether portal gets its obsidian
frame at the end. index.txt in the datapack lists every cell with its state.

The block list and light levels come from the prepared resources (gameplay-facts.json, facts.json), so the
gallery follows the pinned version. The docstring states the tuning standard (Horizon's default Brightness and
Smooth Lighting, HDR10 at Paper White 200 / Peak 500, HORIZON_HDR_DEBUG=1), so anyone judging does it under the
same conditions.

Dev tooling only, nothing in the game changes.

Vanilla reference

None (tooling). The datapack uses only vanilla commands and the 26.3 pack format.

Self-check

pr_ready (tools/pr_ready.py --quick on 9479ecebf0ce, against origin/main at b6c936f82, 34 s)

Check Result
Scope ✅ 1 files, +270 −0
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 398 passed (34 s)
rustfmt ➖ no Rust change
clippy ➖ no Rust change
tests ➖ no crate touched
doc tests ➖ no crate touched
content root tests ➖ content root untouched
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ➖ not run (--quick): CI's parity job picks the affected harnesses
Label skip-release

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/3111 **Author:** [@senjinthedragon](https://github.com/senjinthedragon) **Created:** 10/28/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `hdr-gallery` --- ### 📝 Commits (1) - [`8502d86`](https://github.com/horizon-rust/horizon/commit/8502d86e24d7251d9800c03b2af4543f9b9bd783) tools/hdr_gallery.py: an HDR test gallery of every block that gives light ### 📊 Changes **1 file changed** (+270 additions, -0 deletions) <details> <summary>View changed files</summary> ➕ `tools/hdr_gallery.py` (+270 -0) </details> ### 📄 Description > 🤖 Opened by Senjin's AI agent (Claude Code), not by Senjin. ## What and why Part of #1441. Judging how light sources shine in HDR means looking at each one in the dark, one at a time, under the same settings every time. Placing 100-odd blocks by hand, with their supports and in their brightest state, takes longer than judging them, and the next round needs it all again. `tools/hdr_gallery.py` writes the test bench into a world as a datapack: ```sh python3 tools/hdr_gallery.py --world path/to/saves/MyWorld # --resources if not .local/horizon-client/26.3 ``` Then, in the world (creative, on a flat open spot): - `/reload` - `/function hdr:gallery`: one or two of each family (54), where a verdict goes for the whole family. - `/function hdr:gallery_full`: every block with a light level (108), in its brightest state. Both first run `hdr:setup`: midnight held, no weather, no mobs, no random ticks (lit redstone ore stays lit), effects cleared, and a reminder to keep Brightness and Smooth Lighting at their defaults. Each block sits alone with 6 empty blocks to either side, on grass (stone around fire and lava), against the far wall of a stone tunnel, with what it needs to stay: a wall for wall torches, a ceiling for cave vines, netherrack under fire, soul soil under soul fire, a redstone block under the lamp, lava and sea pickles sunk into the floor. The nether portal gets its obsidian frame at the end. `index.txt` in the datapack lists every cell with its state. The block list and light levels come from the prepared resources (`gameplay-facts.json`, `facts.json`), so the gallery follows the pinned version. The docstring states the tuning standard (Horizon's default Brightness and Smooth Lighting, HDR10 at Paper White 200 / Peak 500, `HORIZON_HDR_DEBUG=1`), so anyone judging does it under the same conditions. Dev tooling only, nothing in the game changes. ## Vanilla reference None (tooling). The datapack uses only vanilla commands and the 26.3 pack format. ## Self-check **pr_ready** (`tools/pr_ready.py --quick` on 9479ecebf0ce, against origin/main at b6c936f82, 34 s) | Check | Result | | --- | --- | | Scope | ✅ 1 files, +270 −0 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 398 passed (34 s) | | rustfmt | ➖ no Rust change | | clippy | ➖ no Rust change | | tests | ➖ no crate touched | | doc tests | ➖ no crate touched | | content root tests | ➖ content root untouched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ➖ not run (--quick): CI's parity job picks the affected harnesses | | Label | `skip-release` | --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:08:06 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#4809
No description provided.