mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 23:55:52 +01:00
[PR #1361] shader_carve: exclude the length byte from shader names (SHADER-CARVE-NAME-LENGTH) #1392
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#1392
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/1361
Author: @x2Tweek
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:fix-carve-name📝 Commits (1)
4adb409Exclude the length byte from carved shader names📊 Changes
4 files changed (+80 additions, -14 deletions)
View changed files
📝
make_game.py(+14 -2)📝
tests/test_shader_carve.py(+22 -0)📝
tests/test_shader_stage_resume.py(+33 -10)📝
tools/shader_carve.py(+11 -2)📄 Description
Claimed in the coordination issue as: SHADER-CARVE-NAME-LENGTH (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7146324024)
What and why
A printable name-length byte can be captured as the first letter of a shader name. Interpret the length after matching the candidate header so both the Python and optional native scanners use the same name handling. Check for a length field immediately before the match to preserve a real first character that happens to have the same value as the matched name length.
The correction changes some output filenames and translation-index keys. Existing work folders need the shaders stage again. Run
python -I make_game.py --stages shaderswith your usual game and work-folder options. A missing or stale carve-source digest tells that stage to recarve, unpack, disassemble and translate.Tested
python -I tests/test_shader_carve.py,python -I tests/test_shader_stage_resume.py,python -I tests/test_shader_stage_manifest.py,python -I tests/test_shader_library.py, andpython -I tests/test_text_write_line_endings.py.cargo build --release --offline --manifest-path tools/shader_carve_native/Cargo.tomland ranpython -I tests/test_shader_carve_native.pywithLEONIDA_TEST_REQUIRE_SHADER_CARVE_NATIVE=1. Also ran the new carve regression withLEONIDA_SHADER_CARVE_NATIVE=0.make_game.py --help, the game-data check andgit diff --checkpassed.GPUs tested: n/a. CPU-only synthetic fixtures and mocked pipeline tools on Windows. No retail corpus run.
AI-assisted: yes.
Checklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.