Repository navigation
#750: float footage follows Working Gamma and is encoded once - #752
Merged
Merged
Conversation
Problem: with no working space and Working Gamma 2.4, a linear EXR still converted with the sRGB curve (0.18 -> 0.4627, After Effects 0.4902): float footage was sRGB-encoded at decode, before the render knew the project's curve. Interpret As Linear Light on float footage then encoded a second time (0.18 -> 0.7255). Fix: FootageSource::frame_with asks for float footage with a FloatCurve (sRGB, a pure 2.4 power curve, or as stored). The renderer asks for the Working Gamma's curve when unmanaged, sRGB when managed, and the stored values when Interpret As Linear Light encodes them afterwards. MediaPool decodes float values that way (Preserve RGB still reads them as stored) and caches each curve apart. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
|
Merged. Thank you for the contribution, @vangel76! If you haven't already, come join us on Discord: https://discord.gg/artcraft. It's the best place to discuss what you're working on next and to coordinate with other contributors. |
h-a-n-a-s-h-i
pushed a commit
that referenced
this pull request
Oct 12, 2026
- Footage sources: the cancellable wrapper (#784) forwards frame_with (#752 float curves) and problem (#887); problem's default lives on the trait. - Media: a called-off decode (#784) is not a footage problem (#887). - Effect Controls rename (#953): Escape cancels (egui drops focus on Escape the same frame), the Rename item is translated; regression test. - i18n (#873): drop the /out-i18n/ ignore rule and the note about an uncommitted script. - Tests: text range selector caps (#926) re-borrow the layer; the RAM preview test (#793) sets the comp's own Resolution (#462). 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.
Fixes #750.
Part of ranked gap #10 "Colour pipeline differences" (docs/gaps.md); the follow-up @Romasikkk reported on #495 after #645.
Problem
With no working space and Working Gamma 2.4, After Effects converts a linear EXR with a pure 2.4 power curve (0.18 → 0.490, 0.051 → 0.290). On main the setting reached Interpret As Linear Light but not float footage:
MediaPoolsRGB-encodes float values at decode, before the renderer knows the project's curve, so a linear EXR still came out at 0.18 → 0.4627. Turning on Interpret As Linear Light for the EXR then encoded a second time on top of the decode's own encoding (0.18 → 0.7255).Fix
effectcraft-render: newFloatCurve(sRGB, a pure 2.4 power curve, or the stored linear values) andFootageSource::frame_with(item, footage, t, size, float). Its default callsframe/frame_at_sizeand ignores the curve, so sources without float footage don't change.Pipe::float_curve(f)picks the curve: the stored values when Interpret As Linear Light encodes them afterwards (once, withlinear_footage_space), otherwise the Working Gamma's curve when unmanaged and sRGB when managed (the working space converts from there). The footage paths (plain, reduced size, separate fields, frame blending, comp proxies) ask through it. The frame-blend cache key includes the curve.effectcraft-media:AlphaOptakes the curve instead of the Preserve RGB flag (Preserve RGB still reads the stored values, whatever is asked).MediaPoolimplementsframe_with, and the decoded-frame cache key holds the curve, so each one decodes and caches separately.frame/frame_atstay sRGB.Integer footage (8/16-bit) decodes the same way whatever the curve. Managed projects without Interpret As Linear Light don't change.
Tests
render::tests_color::float_footage_is_encoded_once_with_the_working_gamma: float footage at Working Gamma 2.4 / 2.2 and in an sRGB working space, each with Interpret As Linear Light off and on. It gives AE's values (0.290 / 0.490 / 0.749 at 2.4) and encodes once. It fails on main (2.4 gives 0.250 / 0.461 / 0.735).media::pool::tests::float_exr_is_encoded_with_the_requested_curve: a float EXR decoded throughMediaPoolwith each curve, plus Preserve RGB overriding the curve and separate cache entries for each curve.Gates
cargo fmt --checkcargo clippy -j 4 -p effectcraft-render -p effectcraft-media --all-targets -- -D warningscargo test -j 4 -p effectcraft-render -p effectcraft-media(all targets): all passcargo xtask layers: okcargo check -p effectcraft-render -p effectcraft-media --target wasm32-unknown-unknownThe full
cargo xtask ciwas not run locally because the machine is shared.What remains
FootageSource::framestill get sRGB-encoded float values: the Footage panel, thumbnails and the tracker's source frames.🤖 Generated with Claude Code