Shader: Add Conductor BSDF Node #114958

Open
Alaska wants to merge 14 commits from Alaska/blender:metallic-bsdf into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.

14 Commits

Author SHA1 Message Date
Alaska b87d86dc37 Fix missing change from merge 2024-02-24 00:20:44 +13:00
Alaska aa10c5d56d Merge branch 'main' into metallic-bsdf 2024-02-24 00:18:15 +13:00
Alaska 45b1a5906a Merge branch 'main' into metallic-bsdf 2024-01-11 01:16:55 +01:00
Alaska 21ffc1d77d Adjust names of inputs
Add a code comment
2023-11-21 00:25:08 +13:00
Alaska cb261fa16a Merge branch 'main' into metallic-bsdf 2023-11-20 22:15:38 +13:00
Alaska 9b1a441acb Add Conductor Fresnel to Conductor BSDF
Notable changes from previous revision of Conductor BSDF:
 - There are three "Fresnel Types" that can be selected on the node.
   -  Conductor Fresnel - Artistic (Default)
      - Uses `bsdf_microfacet_setup_fresnel_conductor()` in Cycles. Takes a Color `Base` and `Tint` input with automatic code to turn it into `n, k` values (fresnel_conductor uses `n, k` values).
   - F82 Tint Fresnel (Old default)
      - Uses `bsdf_microfacet_setup_fresnel_f82_tint()` in Cycles. Takes a Color "Base" and "Tint" input. This option should match the a metallic Principled BSDF material.
   - Conductor Fresnel
      - Uses `bsdf_microfacet_setup_fresnel_conductor()` in Cycles. Takes in `n, k` values.
- Various functions have been added to support the new `Conductor Fresnel - Artistic`.
   - For example, I've added `conductor_ior_from_color` and `conductor_extinction_from_color` fucntions to get `n, k` values from color `Base` and `Tint` inputs.
     - Formula is taken from the paper `"Artist Friendly Metallic Fresnel", Ole Gulbrandsen, 2014`.
     - These are the same formulas used by MaterialX in the `artistic_ior` node.
- General other changes (E.G. Change names of certain inputs, adjust default values, etc.)

TODO:
1. Fix the MaterialX node setup for when we're using the "Conductor Fresnel Type".
2. Adjust names and the descriptions of inputs to explain things. (Feedback from developers would be appreciated).
3. Check with Cycles developers to see if the names of the newly added functions are alright.
4. Wait for general code review. See if any other changes are wanted.
2023-11-20 22:10:41 +13:00
Alaska b48090ecad Add Beckmann dsitrobution to Conductor BSDF node 2023-11-19 16:47:23 +13:00
Alaska 871d0fba84 Merge branch 'main' into metallic-bsdf 2023-11-19 11:23:35 +13:00
Alaska 6ace770d3b Merge branch 'main' into metallic-bsdf 2023-11-16 17:21:20 +13:00
Alaska 482fb698a2 Switch Cycles to it's own unique shader type 2023-11-16 17:08:41 +13:00
Alaska 0d0c0df3d9 Remove unused Microfacet options 2023-11-16 00:07:06 +13:00
Alaska 54c91f8bd3 Intial Cycles support
The material now (incorrectly) renders in Cycles in both SVM and OSL

TODO:
 - Add support for Tint to SVM
 - Use seperate "Conductor BSDF" case instead of reusing glossy closures.
 - Update SVM and OSL to be based on the Principled BSDF Metallic instead of the Glossy BSDF
2023-11-15 17:50:17 +13:00
Alaska 5d6f651aef Intial Implementation of Conductor BSDF
- Node appears in shader editor
- Material renders in EEVEE

TODO: Work on Cycles
2023-11-11 21:41:24 +13:00
Alaska 46bec5539d Intial Implementation of Conductor BSDF
- Node appears in shader editor
- Material renders in EEVEE

TODO: Work on Cycles
2023-11-11 16:50:48 +13:00