mirror of
https://github.com/storytold/photocraft.git
synced 2026-11-13 21:52:54 +00:00
* Color Lookup: keep the .cube input domain and reject the ones we cannot apply DOMAIN_MIN/DOMAIN_MAX (and LUT_3D_INPUT_RANGE) were parsed and thrown away, so a log-domain or extended-range look was applied to plain 0..1 inputs: silently wrong colours, exactly what the in-code comment admitted. The domain now travels with the parsed LutFile (validated: every component finite and min < max), and colorLookup refuses a non-default domain with the reason instead of shifting the look - the same unsupported-over-wrong-output call the codecs make. Honoring a custom domain end to end means carrying it through ColorLookup (doc, compose, gpu, PSD round trip) and stays open as the follow-up. * tests: the colorLookup domain rejection needs a pixel layer active The outer session of the test still had the adjustment layer active, so the command was disabled before reaching the domain rejection - the assertion only passed when the active layer happened to differ. Make it deterministic with a fresh pixel layer. * Color Lookup: bake a 1D .cube's input domain into the resample The 1D branch of parse_cube still ignored DOMAIN_MIN/MAX and LUT_1D_INPUT_RANGE. Since the 1D table is resampled onto a 0..1 cube anyway, the domain is now applied there (saturating outside), and a degenerate domain is rejected like the 3D one. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * cargo fmt after rebasing onto main Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Brandon Thomas <echelon@gmail.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>