Cycles: Add Metallic Tint to Principled BSDF using F82-Tint model #112551

Manually merged
Brecht Van Lommel merged 26 commits from LukasStockner/blender:principled-metallic into main 2023-09-25 19:54:27 +02:00

26 Commits

Author SHA1 Message Date
Lukas Stockner 14eae8df60 Cycles: Add Metallic Tint to Principled BSDF using F82-Tint model
With the default value, this is backwards-compatible.
2023-09-25 03:41:00 +02:00
Lukas Stockner 9f714a61c3 Merge remote-tracking branch 'origin/main' into principled-specular-tint 2023-09-25 02:23:57 +02:00
Weizhen Huang 84ad02cfe7 make format 2023-09-19 19:20:49 +02:00
Weizhen Huang 09c1b3fdc5 Merge branch 'main' into principled-specular-tint 2023-09-19 19:19:23 +02:00
Weizhen Huang d7efd0b658 Add description 2023-09-19 19:11:09 +02:00
Weizhen Huang a1b0ba9812 Add versioning 2023-09-19 19:05:39 +02:00
Weizhen Huang 9a41e1c5e8 Merge branch 'main' into principled-specular-tint 2023-09-18 18:40:30 +02:00
Weizhen Huang b3ddc0dc86 Merge branch 'main' into principled-specular-tint 2023-09-18 16:21:35 +02:00
Weizhen Huang 6a6c371c02 Cleanup: `f0` -> `F0` 2023-09-18 16:15:47 +02:00
Weizhen Huang 06ae037097 Apply the change also in EEVEE-Next 2023-09-18 16:00:11 +02:00
Weizhen Huang d545d3e81b Merge branch 'main' into principled-specular-tint 2023-09-18 15:37:03 +02:00
Weizhen Huang e50dd540d3 Merge branch 'main' into principled-specular-tint 2023-09-18 14:55:31 +02:00
Weizhen Huang 706ba4aa38 Clamp F0 to one 2023-09-14 14:16:41 +02:00
Weizhen Huang 82423d60b9 EEVEE: use btdf_lut for specular components 2023-09-14 14:16:11 +02:00
Weizhen Huang 26e3dd4d0e Revert "Use albedo instead of `transmission_color` for `Fss`"
This reverts commit 1e94c0e96a.
2023-09-14 12:25:46 +02:00
Weizhen Huang 6f728fade2 Revert "Fix: Cycles Principled BSDF specular component wrong IOR when backfacing"
This reverts commit 7f28729e13.
see #112192 (comment)
and 65d56143ab
2023-09-14 12:18:25 +02:00
Weizhen Huang a44cbccbe2 Handle backfacing glass is OSL
the logic was changed in 65d56143ab
2023-09-14 12:17:15 +02:00
Weizhen Huang 837747435c Merge branch 'main' into principled-specular-tint 2023-09-14 12:10:00 +02:00
Weizhen Huang 4e0ed7dcc3 WIP: EEVEE: tint specular reflection in transmission component
TODO:
tint specular
change EEVEE-Next
2023-09-13 23:44:48 +02:00
Weizhen Huang 5983eecddc WIP: EEVEE: tint specular reflection in transmission component
TODO:
tint specular component
change EEVEE-next
add multiscatter energy compensation
2023-09-12 19:37:40 +02:00
Weizhen Huang 7f28729e13 Fix: Cycles Principled BSDF specular component wrong IOR when backfacing
is visible when Transmission value is between 0 and 1.
The behaviour is actually not well defined for specular layer when
coming from inside, but this is at least consistent with the
transmission component and also consistent with the current behaviour in
OSL. Could probably save one closure allocation in svm later.
2023-09-10 00:01:47 +02:00
Weizhen Huang 33181880d7 Cycles: Change specular tint in Principled BSDF from float to color 2023-09-09 23:53:03 +02:00
Weizhen Huang 91a50f0aa0 Use square root of the base color for transmission color
because the color is applied both on entrance and exit. Using square
root makes the resulted color closer to the base color.
2023-09-09 23:49:02 +02:00
Weizhen Huang 7fb8834d30 Color `f0` for transmission component
to be consistent with specular
2023-09-09 23:46:43 +02:00
Weizhen Huang 1e94c0e96a Use albedo instead of `transmission_color` for `Fss`
makes more sense when `transmission_color` is dark
2023-09-09 23:01:45 +02:00
Weizhen Huang 9455ff9743 Refactor: Cycles: weight reflection/refraction lobe selection pdf by tint
Now that there are different Fresnel types and the reflectance can be tinted,
it is better to sample based on the tinted instead of the real Fresnel. Also
avoid computing Fresnel multiple times.
2023-09-09 21:28:30 +02:00