Repository navigation
ritmo-tools pixel bake: the look is the model's too - #225
Merged
Merged
Conversation
Two agents given a written brief tried bake, found its shading worse than their own, and each wrote a projection script to choose tones per face, lines between parts, and details drawn flat on faces. The maintainer liked both results. So bake keeps the geometry and leaves those choices open: - `steps` per facing (top, left, right) in place of the light - `line` on a part: where it meets a part behind it, on that part - `rows` on a face: a flat picture laid on it, turning with the model - `"map": true` writes `<name>.map.json`, each pixel's part, face, facing, depth, and place on its face, for a script to restyle - the camera as `across` and `down`, in a game's own terms; the sun keeps the picture's axes, so it draws as the matching turned camera does The outline no longer breaks at a sharp tip: the lone-pixel cleanup removed outline pixels that met the rest only at a corner. They are now kept and joined through the empty corner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The README's across/down example was Landkeep's camera, which the test agent then copied: generic 2:1 and three-quarter views instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
From the rerun: baked pieces won where the feature is flat and angular, and lost where it is curved or small. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Two agents given a written brief tried
pixel bake, judged its shading worse than their own, and each wrote a projection script to choose the look themselves. The maintainer liked both results. So bake keeps the geometry and leaves those choices to the model.New fields
stepson a part: a ramp step per facing (top,left,right), used instead of the light.lineon a part: a line where the part meets a part behind it, drawn on that part. It can betrue(the outline's color),"step"(one step darker), or a color.rowson aface: a picture drawn flat, laid on the face, and turning with the model. Doors, windows, dials."map": true: writes<name>.map.json, with each pixel's part, face, facing, depth, and place on its face, so a script can restyle the art instead of rebuilding a renderer.camera.across/camera.down: the camera in a game's own terms. The sun stays in the picture's axes, so these draw exactly what the matching turned camera draws (tested pixel for pixel).Fix: the outline broke at a sharp tip, such as a roof's eave. The lone-pixel cleanup was removing outline pixels that touch the rest of the outline only at a corner. Those are now kept, and joined through the empty corner.
The skill's bake bullet says the look is the agent's too, and
PIXEL-ART.mdrecords why. The changesets are a minor for tools and a patch for core's skill.Tested with an agent. The same Landkeep brief went to a fresh Opus 5.5 High agent with this build and the updated skill:
steps,line,rows, andacross/down, and wrote no renderer of its own. Run 1, before this change, wrote a 195-line one.pixel lintis clean on all five.rowswithout declaring them as materials;Verify:
pnpm run check: typecheck, lint, type tests and examples pass. Some tests timed out under a machine load of 100+. Rerun at normal load,packages/toolsand every file that had failed pass: 452 of 452.packages/tools/test/bake.test.tshas 10 new tests: parsing, steps per facing, lines, face rows,.in rows, the map, axes against the turned camera, the outline at a tip, and the map file in the CLI.🤖 Generated with Claude Code