Spread a rounded edge's glint instead of drawing it as a broken line - #380
Merged
Merged
Conversation
The resin dice in the gallery showed thin, dashed white lines along some rounded edges. They looked like white ink picked up by the bends, which take their face's cell at the point under them. They are not: sampled bilinearly, as the GPU does, the printed field on every bend of every shape stays below the half that is a numeral's edge (worst 0.09 on a d10, 0.30 on a d18, nought on a d12 and d20), and a bone die with black numbers showed a light line on the same edge. They are the lacquer's glint. A bend turns the normal through up to 90 degrees in under 0.8 mm, two to four pixels of a gallery frame, and a coat of roughness 0.12 reflects a light from only a few of those degrees, so the highlight is thinner than a pixel and each pixel lands on it or misses it. Against a dark resin body that reads as a dashed white line. Both dice materials are now compiled with Filament's geometric specular anti-aliasing at its default variance and threshold, which raises the body's and the coat's roughness by how fast the normal changes between pixels. Flat faces have a constant normal, so faces, numbers and the tray are unchanged. The settings join the material cache key, so a packet compiled without them is not read back. A JVM test pins that no bend but the d4's (whose spill is by design) samples ink; a device test checks both compiled materials carry the anti-aliasing settings. 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.



Fix for a bug the stacked gallery showed on the Pixel 10a: thin, light dashed lines along some rounded edges of the resin dice.
Cause: the clear coat's glint on the rounded bend, not ink.
Ruled out:
Fix: Filament's geometric specular anti-aliasing on the dice materials, with Filament's defaults (variance 0.15, threshold 0.2). It raises roughness where the normal changes fast between pixels, so flat faces, numbers, the felt and the walls are unchanged. The material cache key now includes these settings, so an old packet isn't read back.
On the Pixel 10a (whole stack):
:render:filamentdevice suite: 51/52. The one failure wasStudioLightDeviceTest's first-launch studio budget at 1001 ms against 1000 in the middle of the full suite, with the phone warm. Run on its own twice it passes: 797 and 793 ms on first launch, 333 and 338 ms from the cache. That first-launch number is drifting up (582 → 797 ms) and sits close to its budget: worth watching.Tests:
RoundedEdgesTest: a bend samples no ink.DiceMaterialTest: the fingerprint and cache key.FilamentStageTest: both materials report the anti-aliasing settings.Based on #379.
🤖 Generated with Claude Code