Light the tray with a photographed room, exposed like a camera - #378
Merged
Merged
Conversation
A CC0 studio panorama (Poly Haven brown_photostudio_02, 1k HDR) lights the dice and the felt instead of a generated gradient: decoded and folded into a cube in Kotlin (Radiance, StudioCube), cached in codeCacheDir (StudioCache), prefiltered by Filament's generatePrefilterMipmap. The camera is exposed by aperture, shutter and ISO 80 so a white floor lands at 0.95; the one-argument setExposure had asked for 26 stops too much and drew every frame white. The tone mapper is linear, because PBR Neutral's toe subtracted the felt's red channel in Rec.2020. The fill lamp, which Filament never drew (one directional light per scene), is now added to the room's irradiance. Shadows are PCF again: PCSS is EVSSM in Filament 1.76 and brought the rim's shadow back as a band along the walls. 4x MSAA replaces FXAA. On the Pixel 10a: the felt #1f5e3a draws as (34, 89, 58); the felt beside every wall is 0.997-1.027 of the felt in the middle; the room builds in 582 ms once and 301 ms from the cache. APK +1.5 MB. 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.



Step 2 on
feature/realistic-rendering: physically based lighting. Squashed from three rounds; each was tested on the Pixel 10a and fixed what the phone found.What it does (decision 89):
Radiance,StudioCube); the file is treated as untrusted and falls back to the gradient.codeCacheDir(StudioCache).generatePrefilterMipmap.filament-utils: it hard-links gltfio into every ABI, which cost +18.8 MB. This costs +1.5 MB.setExposure, which asked for ~26 stops too much and drew every frame white.On the Pixel 10a, with the whole stack (gallery + resin + rounded + this):
:render:filamentdevice suite 49/49.#1f5e3adraws as (34, 89, 58); target ±10 of (31, 94, 58).theFeltBesideTheWallsIsTheFeltInTheMiddle, bar 0.9).Cost to note: about 0.3–0.4 s on the first frame of every cold start, for the prefilter, which can't be cached through Filament's JNI.
Docs:
docs/physics-and-rendering.md("Rendering (normal mode)"), decision 89, the asset licence record, TODO, STATUS.Based on #377.
🤖 Generated with Claude Code