Skip to content

Match After Effects non-legacy Brightness & Contrast - #702

Open
vbasky wants to merge 1 commit into
storytold:mainfrom
vbasky:fix/681-brightness-contrast
Open

vbasky wants to merge 1 commit into
storytold:mainfrom
vbasky:fix/681-brightness-contrast

Conversation

@vbasky

@vbasky vbasky commented Oct 11, 2026

Copy link
Copy Markdown
Contributor

Fixes #681.

Non-legacy Brightness & Contrast used g = 2^(2c), which is much steeper than After Effects (Contrast 100 at v=0.25 was ~8/255 vs AE ~40/255).

Using kasper9n's AE ramp PNGs, Clef (Jev) chose a closed-form brightness-first mild S-curve over keeping the old exponent-4 curve or a discrete 2D LUT. Brightness is a power that pins 0 and 1; contrast uses g = 1 + 0.53 c. CPU and GPU match. B0 C-100.png was treated as a duplicate of C-50 and is not a golden.

Legacy (Use Legacy) is unchanged.

Remaining: strong negative brightness (B-100 / B-150) still has a larger 8-bit error than contrast; that was accepted to ship the screenshot mismatch.

The modern curve used g = 2^(2c), so Contrast 100 crushed 0.25 to about 8/255 while AE is about 40/255. Brightness is now a pin-black-and-white power toward white or black, then a milder S-curve g = 1 + 0.53 c, fitted to kasper9n's AE grey ramps. Legacy linear mode is unchanged. The GPU kernel matches the CPU.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Inaccurate "Brightness & Contrast" effect

1 participant